Skip to content
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

installer --version outputs to stderr. #11

Open
nicholaswilde opened this issue Dec 26, 2020 · 2 comments
Open

installer --version outputs to stderr. #11

nicholaswilde opened this issue Dec 26, 2020 · 2 comments

Comments

@nicholaswilde
Copy link

When running installer --version, the output is directed to stderr instead of stdout. Also, a return character needs to be added to the end.

Referencing this article.

Expected behavior.

$ ./installer --version
0.2.9
$ ./installer --version 1> out.txt 2> error.txt && cat out.txt
0.2.9
$ ./installer --version 1> out.txt 2> error.txt && cat error.txt
null

Actual behavior.

$ ./installer --version
0.2.9$
$ ./installer --version 1> out.txt 2> error.txt && cat out.txt
null
$ ./installer --version 1> out.txt 2> error.txt && cat error.txt
0.2.9$

Environment

$ cat /etc/*-release
NAME="Ubuntu"
VERSION="20.10 (Groovy Gorilla)"
ID=ubuntu
ID_LIKE=debian
PRETTY_NAME="Ubuntu 20.10"
VERSION_ID="20.10"
HOME_URL="https://www.ubuntu.com/"
SUPPORT_URL="https://help.ubuntu.com/"
BUG_REPORT_URL="https://bugs.launchpad.net/ubuntu/"
PRIVACY_POLICY_URL="https://www.ubuntu.com/legal/terms-and-policies/privacy-policy"
VERSION_CODENAME=groovy
UBUNTU_CODENAME=groovy
@jpillora
Copy link
Owner

Agreed. Should go to stdout. Issue belongs https://github.com/jpillora/opts here though. No idea why I decided on stderr many years ago, trying to think now if this change could break anything...

@nicholaswilde
Copy link
Author

I appreciate you looking into this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants