mirror of
https://github.com/golang/go.git
synced 2024-09-22 19:08:30 +00:00
cmd/go: adjust documentation mentioning 'go get'
In module-aware mode, 'go get' no longer builds or installs packages. - 'go generate' explains build commands do not run generate commands. 'go get' is no longer a build command, so this CL removes mention of it. - 'go get' will continue to accept build flags, but they're ignored. The documentation no longer mentions them, though it does mention -x for printing VCS commands. For #43684 Change-Id: I1eea7241eecf72ba9f98238b729d91cc77ec7665 Reviewed-on: https://go-review.googlesource.com/c/go/+/355209 Trust: Jay Conrod <jayconrod@google.com> Run-TryBot: Jay Conrod <jayconrod@google.com> TryBot-Result: Go Bot <gobot@golang.org> Reviewed-by: Bryan C. Mills <bcmills@google.com>
This commit is contained in:
parent
6e0adde1e9
commit
f8bfdc9eda
@ -498,7 +498,7 @@
|
||||
// files. Those commands can run any process but the intent is to
|
||||
// create or update Go source files.
|
||||
//
|
||||
// Go generate is never run automatically by go build, go get, go test,
|
||||
// Go generate is never run automatically by go build, go test,
|
||||
// and so on. It must be run explicitly.
|
||||
//
|
||||
// Go generate scans the file for directives, which are lines of
|
||||
@ -644,8 +644,7 @@
|
||||
//
|
||||
// See 'go help install' or https://golang.org/ref/mod#go-install for details.
|
||||
//
|
||||
// In addition to build flags (listed in 'go help build') 'go get' accepts the
|
||||
// following flags.
|
||||
// 'go get' accepts the following flags.
|
||||
//
|
||||
// The -t flag instructs get to consider modules needed to build tests of
|
||||
// packages specified on the command line.
|
||||
@ -660,6 +659,10 @@
|
||||
// When the -t and -u flags are used together, get will update
|
||||
// test dependencies as well.
|
||||
//
|
||||
// The -x flag prints commands as they are executed. This is useful for
|
||||
// debugging version control commands when a module is downloaded directly
|
||||
// from a repository.
|
||||
//
|
||||
// For more about modules, see https://golang.org/ref/mod.
|
||||
//
|
||||
// For more about specifying packages, see 'go help packages'.
|
||||
|
@ -38,7 +38,7 @@ Generate runs commands described by directives within existing
|
||||
files. Those commands can run any process but the intent is to
|
||||
create or update Go source files.
|
||||
|
||||
Go generate is never run automatically by go build, go get, go test,
|
||||
Go generate is never run automatically by go build, go test,
|
||||
and so on. It must be run explicitly.
|
||||
|
||||
Go generate scans the file for directives, which are lines of
|
||||
|
@ -83,8 +83,7 @@ current directory. For example:
|
||||
|
||||
See 'go help install' or https://golang.org/ref/mod#go-install for details.
|
||||
|
||||
In addition to build flags (listed in 'go help build') 'go get' accepts the
|
||||
following flags.
|
||||
'go get' accepts the following flags.
|
||||
|
||||
The -t flag instructs get to consider modules needed to build tests of
|
||||
packages specified on the command line.
|
||||
@ -99,6 +98,10 @@ but changes the default to select patch releases.
|
||||
When the -t and -u flags are used together, get will update
|
||||
test dependencies as well.
|
||||
|
||||
The -x flag prints commands as they are executed. This is useful for
|
||||
debugging version control commands when a module is downloaded directly
|
||||
from a repository.
|
||||
|
||||
For more about modules, see https://golang.org/ref/mod.
|
||||
|
||||
For more about specifying packages, see 'go help packages'.
|
||||
|
Loading…
Reference in New Issue
Block a user