From a87be597af21b8f7000706b3ed4201022a9b7a8f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bj=C3=B8rn=20Erik=20Pedersen?= Date: Fri, 18 Feb 2022 12:43:59 +0100 Subject: modules: Add modules.Workspace config for Go 1.18 Sets `GOWORK` env var for Go 1.18. Fixes #9525 --- modules/client.go | 1 + 1 file changed, 1 insertion(+) (limited to 'modules/client.go') diff --git a/modules/client.go b/modules/client.go index 17e149ecf..fe0abc462 100644 --- a/modules/client.go +++ b/modules/client.go @@ -90,6 +90,7 @@ func NewClient(cfg ClientConfig) *Client { "GOPRIVATE", mcfg.Private, "GONOPROXY", mcfg.NoProxy, "GOPATH", cfg.CacheDir, + "GOWORK", mcfg.Workspace, // Requires Go 1.18, see https://tip.golang.org/doc/go1.18 // GOCACHE was introduced in Go 1.15. This matches the location derived from GOPATH above. "GOCACHE", filepath.Join(cfg.CacheDir, "pkg", "mod"), ) -- cgit v1.2.3