8000 Make `fish_key_reader` exit normally by charego · Pull Request #6964 · fish-shell/fish-shell · GitHub
[go: up one dir, main page]

Skip to content

Make fish_key_reader exit normally#6964

Merged
zanchey merged 1 commit intofish-shell:masterfrom
charego:key-reader-exit
May 5, 2020
Merged

Make fish_key_reader exit normally#6964
zanchey merged 1 commit intofish-shell:masterfrom
charego:key-reader-exit

Conversation

@charego
Copy link
Contributor
@charego charego commented May 2, 2020

The --help and --version options were returning status 1 instead of 0.

This aligns the behavior of fish, fish_indent, and fish_key_reader.

Also the file descriptor passed to print_help was wrong.

@charego charego changed the title Make fish_key_reader exit normally Make fish_key_reader exit normally May 3, 2020
8000 src/fish_key_reader.cpp Outdated
case 'v': {
std::fwprintf(stdout, L"%s\n", get_fish_version());
return false;
std::fwprintf(stderr, _(L"%ls, version %s\n"), program_name, get_fish_version());
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Probably this should go to stdout as before.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the review. I copied that snippet from fish_indent.cpp. Should it be changed to stdout as well?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes the version flags should all print to stdout

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

They print to stdout now.

@charego charego force-pushed the key-reader-exit branch from bf952ac to aec539a Compare May 4, 2020 20:57
@zanchey zanchey self-assigned this May 5, 2020
@zanchey zanchey added this to the fish 3.2.0 milestone May 5, 2020
@zanchey zanchey merged commit ad020e8 into fish-shell:master May 5, 2020
@zanchey
Copy link
Member
zanchey commented May 5, 2020

Tha 8000 nks!

@charego charego deleted the key-reader-exit branch May 5, 2020 04:39
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Aug 3, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

0