]> Cypherpunks.ru repositories - gostls13.git/commit
cmd/go/internal/modload: ignore $GOPATH/go.mod
authorQuan Tong <quantonganh@gmail.com>
Mon, 6 Nov 2023 01:00:31 +0000 (08:00 +0700)
committerGopher Robot <gobot@golang.org>
Wed, 8 Nov 2023 17:56:44 +0000 (17:56 +0000)
commit0891b17ce53de8350689a89e55583794a12d302e
tree382dd69c30224abbe7275e053d0cf19345f264ff
parent07c388f17c039c0bb9a3fd0fd70bf5494aa7ee2c
cmd/go/internal/modload: ignore $GOPATH/go.mod

The existing implementation returns a fatal error if $GOPATH/go.mod exists.
We couldn't figure out what directory the go tool was treating as $GOPATH
in the error message.

Fixes #46807

Change-Id: If9db4c0377f7c36af9c367398d3da494be04cd41
Reviewed-on: https://go-review.googlesource.com/c/go/+/539596
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Auto-Submit: Bryan Mills <bcmills@google.com>
Reviewed-by: Bryan Mills <bcmills@google.com>
Reviewed-by: Heschi Kreinick <heschi@google.com>
src/cmd/go/internal/modload/init.go
src/cmd/go/testdata/script/env_issue46807.txt [new file with mode: 0644]