From: Sean Liao Date: Sun, 12 Mar 2023 02:34:04 +0000 (+0800) Subject: cmd/go: update help for empty environment variables X-Git-Tag: go1.21rc1~397 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=2ec648aa8c42d1215ddf59c6a461b21fb6723b74;p=gostls13.git cmd/go: update help for empty environment variables Fixes #50335 Change-Id: I44b9dc6afa8c70b5cc8c79fb3ebddc3f45d3cef8 Reviewed-on: https://go-review.googlesource.com/c/go/+/475695 Auto-Submit: Ian Lance Taylor TryBot-Result: Gopher Robot Reviewed-by: Bryan Mills Reviewed-by: Ian Lance Taylor Run-TryBot: Ian Lance Taylor --- diff --git a/src/cmd/go/alldocs.go b/src/cmd/go/alldocs.go index 8bcbd3f764..455a0f7536 100644 --- a/src/cmd/go/alldocs.go +++ b/src/cmd/go/alldocs.go @@ -2098,9 +2098,9 @@ // # Environment variables // // The go command and the tools it invokes consult environment variables -// for configuration. If an environment variable is unset, the go command -// uses a sensible default setting. To see the effective setting of the -// variable , run 'go env '. To change the default setting, +// for configuration. If an environment variable is unset or empty, the go +// command uses a sensible default setting. To see the effective setting of +// the variable , run 'go env '. To change the default setting, // run 'go env -w ='. Defaults changed using 'go env -w' // are recorded in a Go environment configuration file stored in the // per-user configuration directory, as reported by os.UserConfigDir. diff --git a/src/cmd/go/internal/help/helpdoc.go b/src/cmd/go/internal/help/helpdoc.go index cf932136b3..03cda98bbf 100644 --- a/src/cmd/go/internal/help/helpdoc.go +++ b/src/cmd/go/internal/help/helpdoc.go @@ -471,9 +471,9 @@ var HelpEnvironment = &base.Command{ Long: ` The go command and the tools it invokes consult environment variables -for configuration. If an environment variable is unset, the go command -uses a sensible default setting. To see the effective setting of the -variable , run 'go env '. To change the default setting, +for configuration. If an environment variable is unset or empty, the go +command uses a sensible default setting. To see the effective setting of +the variable , run 'go env '. To change the default setting, run 'go env -w ='. Defaults changed using 'go env -w' are recorded in a Go environment configuration file stored in the per-user configuration directory, as reported by os.UserConfigDir.