github.com/NVIDIA/aistore@v1.3.23-0.20240517131212-7df6609be51d/deploy/dev/local/README.md (about) 1 This document is complementary to [Getting Started](/docs/getting_started.md) showing how to configure Go and ensure it is on your path. 2 3 Intended audience includes developers and first-time users, including those who'd never used Go before. 4 5 ## `$GOPATH` and `$PATH` 6 7 There's of course a ton of [tutorials](https://tip.golang.org/doc/tutorial/getting-started) and markdowns on the web, but the gist of it boils down to a single word: `GOPATH`. Namely, setting it up and exporting, e.g.: 8 9 ```console 10 $ mkdir /tmp/go/src /tmp/go/pkg /tmp/go/bin 11 $ export GOPATH=/tmp/go 12 ``` 13 14 Secondly, `$GOPATH/bin` must be in your `$PATH`. Something like: 15 16 ```console 17 $ export PATH=$GOPATH/bin:$PATH 18 ``` 19 20 The intuition behind that is very simple: `$GOPATH` defines location for: 21 22 * Go sources 23 * Go packages 24 * Go binaries 25 26 Yes, all of the above, and respectively: `$GOPATH/src`, `$GOPATH/pkg`, and `$GOPATH/bin`. 27 28 And so, since you'd likely want to run binaries produced out of Go sources, you need to add the path, etc. 29