When using Unix, you have two basic choices. You may not know you had this choice if you already use Terminal (as we went through last Saturday), but your basic choices are between one shell call Z Shell and another called Bash. (This is an oversimplification because there are in fact many more than this but these are the two most popular.)
Z Shell, also known as Zsh, was invented by Paul Falstad in 1990. Like most choices in the world of Unix, people who use Zsh really like it for good reason. It has great features: spell checking, fancy path expansions, and a whole lot more.
Bash was released around the same time by someone else named Brian Fox in 1989. Bash is the default on macOS. It is the one that most people know. It doesn’t have as many shiny features, but it has features of its own. For example, if you’ve ever in your shell navigation to a directory, type a few first letters and press tab. Your shell beeps at you, indicating that there’s more than one option to complete the file path. Then press tab again and your shell shows you a list of options that would match your file path. This is known as double-tab. (Covered last week in this post.)
Bash is by far the more popular because it is the default, but die-hard Unix users and ‘power user’ programmers tend to prefer Zsh.
In 2020, the tables turned when Apple made Zsh the default in Mac OS Big Sur.
|Bash is default||Z Shell is the default|
CentOS (and its derivatives, like Red Hat Enterprise Linux)
Arch Linux (although it is m
|macOS after Big Sur (macOS 11)|
If you’d like to use Z Shell instead of bash, you have to opt-in to it.
If your system is using Bash, you’ll have these files at the location of your home folder.
If you have ZShell, you’ll instead have these files: