3 ms·
Add an environment variable for `GOBIN`, like this in `~/.bashrc` export GOBIN=$GOPATH/bin export PATH=$PATH:$GOBIN Now, whenever you run `go install filenam
by TheAndruu 8y ago
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.