-
-
Notifications
You must be signed in to change notification settings - Fork 552
New issue
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
Don't print help errors to stdout #440
Comments
Ah yep - I see usage of SetOutput is deprecated in the latest spf13/cobra and you can pipe StdOut and StdErr separately. https://godoc.org/github.com/spf13/cobra#Command Will fix. |
Hello, Looks like this might still be an issue
Yields
Error was that I forgot to specify the actual file to query on. But it was concerning that it had a zero exit code. This tripped me up as I tried to assign the output to a variable and it worked without realising there was an error. |
Describe the bug
When yq reports an error, it prints it (along with the usage docs) on standard out. That is unhelpful, especially if I'm piping stdout to another command.
Input Yaml
No yaml is needed to reproduce this.
Command
Actual behavior
Expected behavior
Additional context
None
The text was updated successfully, but these errors were encountered: