1
0
Fork 0
mirror of https://github.com/tldr-pages/tldr.git synced 2025-04-29 23:24:55 +02:00
tldr/pages/common/go-env.md

21 lines
414 B
Markdown
Raw Normal View History

# go env
> Manage environment variables used by the Go toolchain.
> More information: <https://golang.org/cmd/go/#hdr-Print_Go_environment_information>.
- Show all environment variables:
`go env`
- Show a specific environment variable:
`go env {{GOPATH}}`
- Set an environment variable to a value:
`go env -w {{GOBIN}}={{path/to/directory}}`
- Reset an environment variable's value:
`go env -u {{GOBIN}}`