Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
cmd/go: GOBIN inconsistently not required for installing package but required for .go file #23439
What version of Go are you using (
This was referenced
Jan 13, 2018
Thanks @cznic for your comment. What I understand from documentation and implementation is that the name of the argument is
Second suggestion, to
This ticket is intended to fix the inconsistency in
The use of GOPATH/bin only applies to packages stored in GOPATH.
go install /other/file.go is not considered to be in any GOPATH, so it can only use GOBIN.
In the long term, with modules, we expect that people will stop setting GOPATH and then GOBIN may be more important (or maybe it will increase pressure to default to GOPATH/bin).