golang / mock

GoMock is a mocking framework for the Go programming language.
Apache License 2.0
9.3k stars 611 forks source link

Installing mockgen does not get added to path #490

Closed pickfire closed 3 years ago

pickfire commented 3 years ago

Actual behavior Mockgen was added in ~/src/go/bin/mockgen by installing it with GO111MODULE=on go get github.com/golang/mock/mockgen@v1.4.4, but no warnings were given that ~/src/go/bin is not part of PATH environment variables.

Expected behavior A clear and concise warning should be given to users when installing.

To Reproduce Steps to reproduce the behavior

  1. GO111MODULE=on go get github.com/golang/mock/mockgen@v1.4.4

Additional Information

Triage Notes for the Maintainers

codyoss commented 3 years ago

Hey,

All go binaries are by default installed to $GOPATH/bin. It is common practice to add this location to your PATH. It is the responsibility of the user to do so.

There is no warning we could provide in the tooling, but we could add a note to our README. Feel free to open a PR if you are willing.

montogeek commented 3 years ago

There is no warning we could provide in the tooling,

Why?