Here is my file structure.
myproject/
src/ // package src
res/ // package res
main.go // package main
go.mod
I have tried these commands, all worked,but i want to know about how do the command do and the difference?
go build myproject // the module path is “myproject”
go build myproject/src
go build
go build main.go
mje
(Jeff Emanuel)
2
There’s a brief description here go command - cmd/go - Go Packages.
If you want all the details, then add -x after build and it will tell you everything it does.
system
(system)
Closed
3
This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.