![]() | |
![]() Screenshot of a Zsh session | |
Original author(s) | Paul Falstad[1] |
---|---|
Developer(s) | Peter Stephenson, et al.[1] |
Initial release | 1990; 35 years ago (1990) |
Stable release | |
Repository | |
Written in | C |
Operating system | Cross-platform |
Type | Unix shell |
License | MIT-Modern-Variant[3][4] |
Website | zsh.org |
TheZ shell (Zsh) is aUnix shell that can be used as aninteractive loginshell and as acommand interpreter forshell scripting. Zsh is an extendedBourne shell with many improvements, including some features ofBash,ksh, andtcsh.
Zsh was created by Paul Falstad in 1990 while he was a student atPrinceton University. It combines features from bothksh andtcsh, offering functionality such as programmablecommand-line completion, extended fileglobbing, improved variable/array handling, and themeableprompts.
Zsh is available forMicrosoft Windows as part of theUnxUtils collection and has been adopted as the default shell formacOS andKali Linux. The "Oh My Zsh" user community website provides a platform for third-party plug-ins and themes, featuring a large and active contributor base.
Paul Falstad wrote the first version of Zsh in 1990[5] while a student atPrinceton University.[6] The namezsh derives from the name ofYale professor Zhong Shao (then a teaching assistant at Princeton University) – Paul Falstad regarded Shao'slogin, "zsh", as a good name for a shell.[7][8]
Zsh was at first intended to be a subset ofcsh for theAmiga, but expanded far beyond that. By the time of the release of version 1.0 in 1990 the aim was to be a cross between ksh and tcsh –a powerful "command and programming language" that is well-designed and logical (like ksh), but also built for humans (like tcsh), with all the neat features like spell checking, login/logout watching and termcap support that were "probably too weird to make it into an AT&T product".[9]
Zsh is available forMicrosoft Windows as part of theUnxUtils collection ofnativeWin32ports of commonGNU Unix-like utilities.[10]
In 2019,macOS Catalina adopted Zsh as the default login shell, replacing theGPLv2 licensed version ofBash,[11] and when Bash is run interactively on Catalina, a warning is shown by default.[12]
In 2020,Kali Linux adopted Zsh as the default shell since its 2020.4 release.[13]
Features include:[14]
/bin/sh
where
command. Works like thewhich
command but shows all locations of the target command in the directories specified in$PATH
rather than only the one that will be used.~mydir
, which then behave the way~
and~user
do.A user community website known as "Oh My Zsh" collects third-party plug-ins and themes for the Z shell. As of 2024, theirGitHub repository has over 2300 contributors, over 300 plug-ins, and over 140 themes. It also comes with an auto-update tool that makes it easier to keep installed plug-ins and themes updated.[16]