Commit 64d8846a authored by Jay Conrod's avatar Jay Conrod
Browse files

cmd/go: print hint when 'go install' run without version outside module

If 'go install' is invoked in module mode outside a module with a
package that could only be loaded from a module, it will now suggest
running 'go install pkg@latest'.

'go install' will still work outside a module on packages in std and
cmd, as well as .go files specified on the command line.

Fixes #42638

Change-Id: Ib0963935f028b7656178bc04a279b1114de35fbb
Reviewed-on: https://go-review.googlesource.com/c/go/+/277355


Run-TryBot: Jay Conrod <jayconrod@google.com>
Trust: Jay Conrod <jayconrod@google.com>
Reviewed-by: default avatarBryan C. Mills <bcmills@google.com>
parent 451b6b38
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment