Hacker News new | past | comments | ask | show | jobs | submit login

Add an environment variable for `GOBIN`, like this in `~/.bashrc`

export GOBIN=$GOPATH/bin

export PATH=$PATH:$GOBIN

Now, whenever you run `go install filename.go`, you'll automatically be able to run it anywhere on your machine.




Join us for AI Startup School this June 16-17 in San Francisco!

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: