From e9bd9da77a0cb90da2d7b16c267817de9f78fca6 Mon Sep 17 00:00:00 2001 From: gonejack Date: Mon, 11 May 2020 12:03:05 +0800 Subject: [PATCH] go-env: apply suggestions Signed-off-by: gonejack --- pages/common/go-env.md | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/pages/common/go-env.md b/pages/common/go-env.md index dbaa076c0..e66a7d0b2 100644 --- a/pages/common/go-env.md +++ b/pages/common/go-env.md @@ -1,16 +1,20 @@ # go env -> Tool for printing Go environment information. -> More information: . +> Manage environment variables used by the Go toolchain. +> More information: . -- Show all go environment information: +- Show all environment variables: `go env` -- Show specific environment variable: +- Show an environment variable: `go env {{GOPATH}}` -- Set go environment value: +- Set an environment value: -`go env -w {{NAME}}={{VALUE}}` +`go env -w {{GOBIN}}={{path/to/directory}}` + +- Reset an environment value: + +`go env -u {{GOBIN}}`