Always wanted to move from zsh to fish, but never found a good excuse to spend time on that. Recently a new motherboard for the laptop arrived, this event created a need to wipe entire system clean so we can start over.

That’s a good excuse not to install zsh and use fish!

Why

Often people complain that zsh takes a while to boot for every new terminal. This is indeed annoying, but not zsh’s fault. The main culprit here is widely used oh-my-zsh , but prezto solves this issue for good. And I’ve been using it for years!

My main complaints have been about other, smaller issues:

  • While prezto is great, the installation and update process is not enjoyable. I’ve gone through the setup at least 10 times in the last 3 years, and I still mess something up at first try.
  • ZSH’s strict attributes parser has forced me to ‘quote’ and escape some things better. It’s a well-known quirk at this point, but it still gets on my nerves every time. Most of these “zsh bites me when I forget to quote” problems either do not exist in fish or are greatly reduced, because fish’s grammar is simpler: no history expansion, no glob qualifiers, no K-style extended globs, no parameter flags, no arithmetic in $((…)), etc.
  • Configuration for bash and zsh is hectic and scattered across multiple files (~/.bashrc, ~/.bash_profile, ~/.zshrc, etc). There are multitude of ways to organize organize and maintain these better, non of those approaches never left my satisfied. All fish config files could be found in ~/.config/fish/ folder, that’s a great default!

Nothing fish-y here

Fish has been a blast so far!

It comes with syntax highlighting, suggestions, and completions based on man pages—out of the box, no plugins needed. But we can cherry-pick the plugins if anything extra was needed.

So I decided to make a default right away. On Fedora this take exactly three command to accomplish.

sudo dnf install fish
sudo dnf install util-linux-user # fedora needs this package to install default shells.
chsh -s /usr/bin/fish

But things only get better from here with just couple of more plugins. And fish comes with a awesome package manager called - Fisher: A proper package manager!

It will get handy, so let’s install Fisher with any further ado.

curl -sL https://raw.githubusercontent.com/jorgebucaran/fisher/main/functions/fisher.fish | source && fisher install jorgebucaran/fisher

Powerline prompt

Bobthefish theme for Fish One of the main selling features of zsh is a git-aware powerline prompt. Fish comes with a pretty decent port of this theme.

fisher oh-my-fish/theme-bobthefish

Every Nord theme fanatic will need to insert one line into a ~/.config/fish/config.fish.

set -g theme_color_scheme nord

Directory jumper

cd is the most popular command used in a terminal by far, so since forever I relied on rupa/z to jump through directories. There are modern alternatives, but original has never failed me.

But rupa/z was a bit of a pain to get working during setup. So fish port of Z and fisher package manager made this a breeze!

fisher install jethrokuan/z

fish comes with built-in history search functionality available through ctrl+r. This would previously require a plugin in zsh, but this ix`xs built in. Adding fzf to this turns this already powerful feature into an overpowered one.

fisher install PatrickF1/fzf.fish

Fish search feature powered by fzf

Conclusion

All in all - Fish is a great improvement over ZSH. It might not be worth it for people that don’t touch terminal as much as I do. But for me, it’s a small productivity boost that keeps on giving every day.