Ben Chuanlong Du's Blog

It is never too late to learn.

Change the Default Shell in Linux

Things on this page are fragmentary and immature notes/thoughts of the author. Please read with your own judgement!

Atomic Linux Distributions

How to change the default shell in fedora silverblue?

sudo usermod --shell $(which fish) $(id -un)

Mutable Linux Distributions

sudo chsh -s $(which fish) $(id -un)

You have to add the path of fish into /etc/shells, if you get the error message "chsh: /usr/bin/fish is an invalid shell".

Log out and then log in (or simplify reboot) for the change to take effect.

Comments