Skip to content

Instantly share code, notes, and snippets.

@francisco-rojas
Last active May 11, 2019 20:22
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save francisco-rojas/a750bf2036e884377f54e342bb74cae8 to your computer and use it in GitHub Desktop.
Save francisco-rojas/a750bf2036e884377f54e342bb74cae8 to your computer and use it in GitHub Desktop.
The Go Programming Language Book

Commands

Comple a program: $ go build helloworld.go

$ ./helloworld
Hello, BF

Build and install program: $ go install github.com/user/hello or

$ cd $GOPATH/src/github.com/user/hello
$ go install

Run the program: $ $GOPATH/bin/hello or $ hello

go run command compiles the source code from one or more source files whose names end in .go, lin ks it with librar ies, then runs the resulting executable file. $ go run helloworld.go

References

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment