Go CLI (Command Line Interface)
Usual commands
Command | Action |
---|---|
go version | Displays version |
go run . | Executes the code |
go build | Compiles a code (creates an executable binary) |
go mod init <domain>/<app> | Creates go.mod file |
go install <domain>/<pkg> | Builds and installs the program with the go tool (in $HOME/go/bin/hello or %USERPROFILE%\go\bin\hello.exe) |