mirror of
https://github.com/golang/go
synced 2024-11-24 03:40:16 -07:00
cmd/api: ensure GOPATH always points to the correct go.tools
R=golang-codereviews, dave, bradfitz CC=golang-codereviews https://golang.org/cl/51000043
This commit is contained in:
parent
cefe6ac9a1
commit
fa6ffc6c9b
@ -46,7 +46,7 @@ func main() {
|
||||
gopath := prepGoPath()
|
||||
|
||||
cmd := exec.Command("go", "install", "--tags=api_tool", "cmd/api")
|
||||
cmd.Env = append([]string{"GOPATH=" + gopath}, filterOut(os.Environ(), "GOARCH")...)
|
||||
cmd.Env = append(filterOut(os.Environ(), "GOARCH", "GOPATH"), "GOPATH="+gopath)
|
||||
out, err := cmd.CombinedOutput()
|
||||
if err != nil {
|
||||
log.Fatalf("Error installing cmd/api: %v\n%s", err, out)
|
||||
|
Loading…
Reference in New Issue
Block a user