aboutsummaryrefslogtreecommitdiff
path: root/src/cmd/go/internal/get/get.go
diff options
context:
space:
mode:
authorMarko Mudrinic <mudrinic.mare@gmail.com>2017-06-15 19:15:47 +0200
committerIan Lance Taylor <iant@golang.org>2017-06-15 21:20:46 +0000
commit6ce5067117268eff1c9ca6077371d7c8f4d749e3 (patch)
treee119ecb71988312113d42e87760966d5730c05d5 /src/cmd/go/internal/get/get.go
parenta9fc249f5f5c2485847c63fef226067002408ce4 (diff)
downloadgo-6ce5067117268eff1c9ca6077371d7c8f4d749e3.tar.gz
go-6ce5067117268eff1c9ca6077371d7c8f4d749e3.zip
cmd/go: improve documentation on defaults for get
The existing docs states that, get looks for a branch or tag that matches the locally installed version of Go. First, this is only working for "go1", so it could be confusing. Second, "If no such version exists it retrieves the most recent version of the package". It's more the default branch, by git defaults, rather than most recent version. This should address the potential unclear parts. Fixes #20320 Change-Id: Id7d727d88dc350c9902974b64fa28c3766f7e245 Reviewed-on: https://go-review.googlesource.com/45890 Reviewed-by: Ian Lance Taylor <iant@golang.org>
Diffstat (limited to 'src/cmd/go/internal/get/get.go')
-rw-r--r--src/cmd/go/internal/get/get.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/cmd/go/internal/get/get.go b/src/cmd/go/internal/get/get.go
index 6291a72fc7..550321198d 100644
--- a/src/cmd/go/internal/get/get.go
+++ b/src/cmd/go/internal/get/get.go
@@ -60,8 +60,8 @@ get uses the first one. For more details see: 'go help gopath'.
When checking out or updating a package, get looks for a branch or tag
that matches the locally installed version of Go. The most important
rule is that if the local installation is running version "go1", get
-searches for a branch or tag named "go1". If no such version exists it
-retrieves the most recent version of the package.
+searches for a branch or tag named "go1". If no such version exists
+it retrieves the default branch of the package.
When go get checks out or updates a Git repository,
it also updates any git submodules referenced by the repository.