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

Make stderr redirection compatible with Fish 3.0. #14

Merged
merged 1 commit into from
Jan 14, 2019

Conversation

bobthecow
Copy link
Member

Fish has deprecated ^ as a shortcut for stderr redirection in 3.0. Replace it with the more
compatible 2>.

See oh-my-fish/oh-my-fish#609 and oh-my-fish/oh-my-fish#618

@@ -8,7 +8,7 @@ function z -d "jump around"
Z_STATUS=$?
echo "$PWD" >&2
exit $Z_STATUS
' bash $argv ^| read -l Z_PWD
' bash $argv 2>| read -l Z_PWD
Copy link
Member

Choose a reason for hiding this comment

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

My Bash-fu is weak here, what does ^| do? This might be a false positive.

Copy link
Member Author

Choose a reason for hiding this comment

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

It pipes stderr to the next command. See the docs here … which, incidentally, only show the 2>| version and not ^|.

@scorphus scorphus merged commit ecdeaea into oh-my-fish:master Jan 14, 2019
@scorphus
Copy link
Member

Thanks @bobthecow 🔥

@bobthecow bobthecow deleted the fish-three branch January 14, 2019 18:21
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

Successfully merging this pull request may close these issues.

3 participants