We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
go version
go version devel +81555cb4f3 Tue Aug 14 09:19:38 2018 +0000 darwin/amd64
Yes, latest master.
cd `mktemp -d` go mod init example.com/foo > /dev/null
I expect to see no output.
$ go mod init example.com/foo > /dev/null go: creating new go.mod: module example.com/foo
go mod init writes this message to Stderr.
go mod init
I would prefer if it wrote to stdout instead, so I could ignore the output in my script.
And I definitely don't want to ignore the stderr - in case of any error occurs.
The text was updated successfully, but these errors were encountered:
Using standard error for non-error messages is fine. For example, the log package uses standard error by default.
log
If you want to ignore output as long as no error happened, simply keep the output somewhere, and only use it if the exit code is non-zero.
Sorry, something went wrong.
Thanks, that makes sense. I just thought it's not an intended behaviour.
Closing.
No branches or pull requests
What version of Go are you using (
go version
)?go version devel +81555cb4f3 Tue Aug 14 09:19:38 2018 +0000 darwin/amd64
Does this issue reproduce with the latest release?
Yes, latest master.
What did you do?
What did you expect to see?
I expect to see no output.
What did you see instead?
go mod init
writes this message to Stderr.I would prefer if it wrote to stdout instead, so I could ignore the output in my script.
And I definitely don't want to ignore the stderr - in case of any error occurs.
The text was updated successfully, but these errors were encountered: