Re:Fish: A user-friendly command line shell for macOS, Linux...
by nonsince on Wednesday December 13, 2017 @07:35AM
(#15913821)
I really like that you have to use `env` in fish, since it's cross-shell - it works in bash/zsh/dash/whatever. The `A=b foo` syntax is an unnecessary appendix in the syntax that complicates matters while only saving 4 characters.
Re:Fish: A user-friendly command line shell for macOS, Linux...
by Pete_D on Wednesday December 13, 2017 @02:05PM
(#15916588)
It's not just to save typing - having an `A=b foo` form built-in instead of relying on an external program means `foo` can be an alias or shell function.
Re:Fish: A user-friendly command line shell for macOS, Linux...
by jhasse on Wednesday December 13, 2017 @08:03AM
(#15913935)
I agree and think the best fix would be if the syntax would be forbidden in bash/zsh. Problem is: Millions of code snippets on the Internet not using env.
Re:Fish: A user-friendly command line shell for macOS, Linux...
by nine_k on Wednesday December 13, 2017 @11:13AM
(#15915123)
For one-liners, typing `env ` before pasting is likely not too much work. For longer scripts, you'd have to rewrite much of the text anyway.
Re:Fish: A user-friendly command line shell for macOS, Linux...
by jhasse on Wednesday December 13, 2017 @11:39AM
(#15915327)
often there's stuff like
cd build && LD_LIBRARY_PATH=../lib ./foo
:/It's no dealbreaker though, I still use fish and love it :) Just a minor annoyance ;)
Re:Fish: A user-friendly command line shell for macOS, Linux...
by vram22 on Wednesday December 13, 2017 @09:07AM
(#15914238)
That syntax is from very early days of sh itself (predecessor of bash), IIRC. So removing it would break many scripts, as sibling comment by jhasse said.
Re:Fish: A user-friendly command line shell for macOS, Linux...
by knutae on Wednesday December 13, 2017 @08:59AM
(#15914211)
Agree with these, and would like to add one more:
$(subcommand)
as an alternative to (subcommand)
PS: I have been using fish as my primary shell for about a year now, very happy with it. :)
Re:Fish: A user-friendly command line shell for macOS, Linux...
by jhasse on Wednesday December 13, 2017 @11:41AM
(#15915340)
Good news: Another dev mentioned that they are already discussing this: https://news.ycombinator.com/item?id=15913358
Re:Fish: A user-friendly command line shell for macOS, Linux...
by mattgreenrocks on Wednesday December 13, 2017 @07:01AM
(#15913683)
Yes please, even if we have to opt in to this behavior with a patronizing env var :)
That and support for
(not having to prepend "env ") are what's stopping me from recommending fish to others.Btw: Big thank you for fish, it's awesome!