I\'m trying to set my $GOPATH
variable to run some example code on my machine:
$ smitego-example go run main.go
main.go:5:2: cannot find packag
The http://www.golang-book.com/guides/machine_setup#osx
only has instructions for setting the path on ~/.bashrc
, not ~/.bash_profile
which thanks to this thread was able to get my example file to build.
export GOPATH=$HOME
export PATH=$PATH:$GOPATH/bin
Other Mac users need to add the above to their ~/.bash_profile
.