From 1fbdae5c3ad9aaaf827bed14a5e1e4cbd547a37c Mon Sep 17 00:00:00 2001 From: Jaana Burcu Dogan Date: Fri, 6 Jan 2017 15:09:10 -0800 Subject: cmd/go: add link to env varible guide to set custom GOPATH Also moves the GOPATH env variable guide to golang.org/wiki/SettingGOPATH. Fixes #18294. Change-Id: I88a2ce550df7466f8d2388d86bc8476dcf3c2ad6 Reviewed-on: https://go-review.googlesource.com/34918 Reviewed-by: Brad Fitzpatrick --- doc/code.html | 2 +- src/cmd/go/alldocs.go | 2 ++ src/cmd/go/help.go | 2 ++ 3 files changed, 5 insertions(+), 1 deletion(-) diff --git a/doc/code.html b/doc/code.html index 703f38a21a..796431aa14 100644 --- a/doc/code.html +++ b/doc/code.html @@ -166,7 +166,7 @@ To learn more about the GOPATH environment variable, see

To use a custom workspace location, -set the GOPATH environment variable. +set the GOPATH environment variable.

Import paths

diff --git a/src/cmd/go/alldocs.go b/src/cmd/go/alldocs.go index 57716a53f8..e93fd6ebed 100644 --- a/src/cmd/go/alldocs.go +++ b/src/cmd/go/alldocs.go @@ -935,6 +935,8 @@ // unless that directory holds a Go distribution. // Run "go env GOPATH" to see the current GOPATH. // +// See https://golang.org/wiki/SettingGOPATH to set a custom GOPATH. +// // Each directory listed in GOPATH must have a prescribed structure: // // The src directory holds source code. The path below src diff --git a/src/cmd/go/help.go b/src/cmd/go/help.go index fb69d8ec54..0c663ad463 100644 --- a/src/cmd/go/help.go +++ b/src/cmd/go/help.go @@ -295,6 +295,8 @@ to a subdirectory named "go" in the user's home directory unless that directory holds a Go distribution. Run "go env GOPATH" to see the current GOPATH. +See https://golang.org/wiki/SettingGOPATH to set a custom GOPATH. + Each directory listed in GOPATH must have a prescribed structure: The src directory holds source code. The path below src -- cgit v1.2.3-54-g00ecf