Live data from Hacker News

Fish 4

github.com

21–30 of 113 posts

Re: Fish 4

#22
post #6

I've used Fish for many years, but frankly only for the great autocompletion. The streamlined theme/prompt system and oh-my-fish plugin management are quite nice too, but minor. The rest of Fish features that are not bash-compatible are rather a pain, particularly environment variable management. In principle these features have a better design than in bash, but not that much better, and their use is infrequent enoug…

The better syntax used to be a selling point, but now with AI being able to generate any trivial one-liner and minor scripts you need on a day-to-day basics, have a bad syntax would only affect bigger projects, which I would not write in Fish shell anyway. It's a hard sell.

Generative AI might be able to generate them, but it's still on you to understand the result and check that it indeed does what you want. And with the sometimes very nuance- or foot-gun-rich syntax of bash, that's rather a significant burden, if you're not familiar enough with the syntax to write the script yourself in the first place.

Re: Fish 4

#23
post #6

I've used Fish for many years, but frankly only for the great autocompletion. The streamlined theme/prompt system and oh-my-fish plugin management are quite nice too, but minor. The rest of Fish features that are not bash-compatible are rather a pain, particularly environment variable management. In principle these features have a better design than in bash, but not that much better, and their use is infrequent enoug…

ZSH is pretty compatible and has great auto completion. The best thing for me is inline documentation (bash-completion only shows the list of available completions and you have to derive their meanings by yourself).

It's also much easier to write your own completion scripts than for bash. The syntax is relatively sane, although fish completion scripts are much cleaner than bash or ZSH.

Stick to plain ZSH to avoid losing performance on bloated mess like oh-my-zsh, add fzf to quickly dig through history and find files/directories, and it's really the best option we have.

Re: Fish 4

#24
post #6

I've used Fish for many years, but frankly only for the great autocompletion. The streamlined theme/prompt system and oh-my-fish plugin management are quite nice too, but minor. The rest of Fish features that are not bash-compatible are rather a pain, particularly environment variable management. In principle these features have a better design than in bash, but not that much better, and their use is infrequent enoug…

This.

I've been using fish as my primary shell for a couple years, primarily for the autocompletion. I started off with some zsh plugins that made the shell TOO fancy (and slow). I'd really like to see it be compatible but with some compelling improvements, rather than having them be just incompatible. Every time I can't do $() or fi... But for anything slightly complex I'll drop back down to bash rather than figure out the fish way to do it, because those things are rare enough that I have a hard time keeping them in my head.

I guess I could ask an LLM how to do it in fish, but for things that I already have stuck in my head it's just easier to drop to bash.

Re: Fish 4

#25

Earlier quoted context omitted.

The better syntax used to be a selling point, but now with AI being able to generate any trivial one-liner and minor scripts you need on a day-to-day basics, have a bad syntax would only affect bigger projects, which I would not write in Fish shell anyway. It's a hard sell.

Speak for yourself, but I would not want to be beholden to AI for every trivial shell one-liner. "Sorry boss, ChatGPT is down, I can't count how many *.txt files are in this directory. See you tomorrow!" I'll take the better syntax, thanks.

Heaven forbid you read a man page. Even though Bash is weird, it's fully documented.

Re: Fish 4

#28

If you use Homebrew it’s not available there yet, but it’s being added. See https://github.com/Homebrew/homebrew-core/pull/209124 .

You can just get the binary from the github, it's just a single executable! Or compile it yourself with one command (cargo build --release)

Re: Fish 4

#29
post #6

I've used Fish for many years, but frankly only for the great autocompletion. The streamlined theme/prompt system and oh-my-fish plugin management are quite nice too, but minor. The rest of Fish features that are not bash-compatible are rather a pain, particularly environment variable management. In principle these features have a better design than in bash, but not that much better, and their use is infrequent enoug…

It's the opposite for me; things that are intuitive in Fish would involve inscrutable magic incantations copied from StackOverflow in Bash.

If you only want to use Fish for the autocompletion though, you can! Bash is always still there alongside Fish, you can just open a Bash shell when you're copypasting instructions, or `bash $SCRIPT` any scripts.

Re: Fish 4

#30
I recently built my own shell to better understand its complexity and how it works under the hood. I also implemented redirections and partial tab completion. While I get that writing a shell isn’t the easiest task, I still don’t fully understand why there are so many different ones. I’ve been using the default shell on macOS, and so far, it works just fine.
Post reply on HN