Closed
Description
Thanks for creating such an awesome shell! I've been enjoying using it, especially when scripting.
I'm using Fish 2.7.0 on macOS 10.13.2 inside of a custom tmux terminal profile.
I'd like to request you guys add support for the &&
and ||
operators. I know fish supports and
and or
, but using them feels a bit awkward, especially with the required semicolon.
Going off of the Fish Design Document:
- The law of orthogonality: My suggestion is a violation of this rule. There's no way around that other than the idea that it's syntactic sugar.
- The law of user focus: I don't know about anyone else, but I expected these operators to exist when I first used Fish. They're almost universal across other languages and shells, and they're the first thing I reached for. I realized that's a sample size of one, but I wonder if other people expect the same thing. The use of
;
also requires the user to understand thatand
is a command, which adds a bit of cognitive load. - The law of discoverability: When I type
&&
in a command, Fish prints out an error message telling me what I should have usedand
instead. However, I wish would just do what I wanted instead. This feels like when I typebrew update <app>
, and it tells me I should have typed inbrew upgrade <app>
.
I realize this is a small thing, but it's something I've missed from zsh.