Shell Flavors
Many different Unix shells are available. This quick reference describes the three most popular shells:
The GNU Project’s Bash (Bourne-Again SHell), arguably the most popular shell in use today. It is a superset of the original Bourne shell , including command-line editing and many features first implemented in the Korn shell.
The Korn shell, a superset of the original Bourne shell that lets you edit the command line. There are two commonly available versions of the Korn shell, distinguished by the year they were released, and referred to in this book as ksh88 and ksh93 respectively.
The “Tenex” C shell, an enhanced version of the original BSD C shell, which uses C-like syntax and is more convenient for the interactive user than the original Bourne shell.
The original Bourne shell is available as /bin/sh on commercial Unix systems, and if
invoked as sh
, Bash will do its
best to emulate the original Bourne shell’s behavior. However, it is
rare today to find the original Bourne shell being used interactively
as a login shell; other shells that provide better interactive
features and the Bourne shell’s programming language, such as Bash and
ksh, are more popular. However,
when writing shell scripts, most people are careful to restrict
themselves to just those features of the Bourne shell.
The /etc/passwd file determines which shell takes effect during your interactive Unix session. When you log in, the system checks your entry in /etc/passwd. The last field of each entry names ...
Get Unix in a Nutshell, 4th Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.