This is primarily focused on folks who don’t use Go tooling everyday, but want to use the Go tools. Maybe you need help getting up and running?
Go Binaries
Tools that can compile to a Go binary, such as CLI tools or a web server, can be installed from source easily by running go install
.
However, you require a few things to do this.
- Go installed 😀
- Using aqua makes this easy.
- Although the binaries are dropped into a path, it’s not in your
PATH
by default. Hence, you need to ensure that your shell of choice has this path added for global discovery of the binaries.- Ensure binaries can be found.
export PATH="$(go env GOPATH)/bin:${PATH}"
- Ensure binaries can be found.
- Knowledge of the correct invocation method.
Setup Path Variables So Go Tooling Can Be Found
=== “linux/darwin”
```shell title="linux (.zshenv, .bashrc, etc)"
# If using private, then you can set something like this: export GOPRIVATE=dev.azure.com
export GOPATH="${HOME}/go"
export GOBIN="${HOME}/go/bin"
export PATH="${GOBIN}:${PATH}"
```
windows
|
|
Webmentions
(No webmentions yet.)