1
0
mirror of https://github.com/golang/go synced 2024-11-17 08:04:46 -07:00

cmd/go: document 'go install cmd@version' ignores vendor directories

For #48332

Change-Id: I708eb3e8f3f386f03210b7117d9ab8b0be2125bb
Reviewed-on: https://go-review.googlesource.com/c/go/+/349591
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:
Jay Conrod 2021-09-13 09:16:39 -07:00
parent ad97d204f0
commit c3b217a0e5
2 changed files with 10 additions and 4 deletions

View File

@ -702,14 +702,17 @@
//
// - All arguments must refer to packages in the same module at the same version.
//
// - Package path arguments must refer to main packages. Pattern arguments
// will only match main packages.
//
// - No module is considered the "main" module. If the module containing
// packages named on the command line has a go.mod file, it must not contain
// directives (replace and exclude) that would cause it to be interpreted
// differently than if it were the main module. The module must not require
// a higher version of itself.
//
// - Package path arguments must refer to main packages. Pattern arguments
// will only match main packages.
// - Vendor directories are not used in any module. (Vendor directories are not
// included in the module zip files downloaded by 'go install'.)
//
// If the arguments don't have version suffixes, "go install" may run in
// module-aware mode or GOPATH mode, depending on the GO111MODULE environment

View File

@ -496,14 +496,17 @@ allowed, even if they refer to the same version.
- All arguments must refer to packages in the same module at the same version.
- Package path arguments must refer to main packages. Pattern arguments
will only match main packages.
- No module is considered the "main" module. If the module containing
packages named on the command line has a go.mod file, it must not contain
directives (replace and exclude) that would cause it to be interpreted
differently than if it were the main module. The module must not require
a higher version of itself.
- Package path arguments must refer to main packages. Pattern arguments
will only match main packages.
- Vendor directories are not used in any module. (Vendor directories are not
included in the module zip files downloaded by 'go install'.)
If the arguments don't have version suffixes, "go install" may run in
module-aware mode or GOPATH mode, depending on the GO111MODULE environment