There are far too many ways to set a GOPATH in this extension. We need to centralize them and provide users with common workflows to follow. Some thoughts:
- We should deprecate
go.toolsGopath for Go versions over 1.11. Modules renders the reasoning behind this setting obsolete.
- We should figure out what to do with
go.gopath vs. setting GOPATH in go.toolsEnvVars. Which one overrides the other? I have no idea what happens right now.
- What happens if a user sets
GOBIN in go.toolsEnvVars?
- We should decide if
go.inferGopath makes sense in a modules world.
- We should prioritize binaries on a user's
PATH and only fallback to GOPATH/bin or GOBIN if the binary is not on the PATH.
There are far too many ways to set a
GOPATHin this extension. We need to centralize them and provide users with common workflows to follow. Some thoughts:go.toolsGopathfor Go versions over 1.11. Modules renders the reasoning behind this setting obsolete.go.gopathvs. settingGOPATHingo.toolsEnvVars. Which one overrides the other? I have no idea what happens right now.GOBINingo.toolsEnvVars?go.inferGopathmakes sense in a modules world.PATHand only fallback toGOPATH/binorGOBINif the binary is not on thePATH.