bash vs zsh on terminal
bash vs zsh on terminal. What is the best way to go?
MacBook Pro 16″, macOS 13.4
bash vs zsh on terminal. What is the best way to go?
MacBook Pro 16″, macOS 13.4
Zsh does not read Bash dot files, and you will need just one really, which is .zshrc which the Terminal reads when it is launched. The following Zsh HERE document can be copied/pasted into the Terminal and followed by a return to write a new ~/.zshrc file:
<<"EOF" > ~/.zshrc
export PATH=".:/usr/local/bin:${PATH}"
PS1="%m: %~ %% "
EOF
If you are using homebrew on an Apple Silicon Mac, you may want to alter your PATH so you can see brew installed binaries:
<<"EOF" > ~/.zshrc
export PATH=".:/usr/local/bin:/opt/homebrew/bin:${PATH}"
PS1="%m: %~ %% "
EOF
and then:
source ~/.zshrc
The Zsh man pages are shown in:
man zshall
and the current documentation for the Zsh shell is there.
Use whatever shell works for your needs. Whichever you prefer. Or use a different shell entirely.
Both bash and zsh have been around for a long while on macOS, and neither is going away.
bash isn’t going to get updated, but you can update it yourself.
Apple is defaulting new logins to zsh, and is updating that.
The earliest shell used with OS X was tcsh, so this zsh switch isn’t the first shell change.
And tcsh is still available with macOS 13.
Thank you for your response! I appreciate it. I have bash, and was considering switching to zsh. Thank you for the feedback!
Thank you for your response to my question! I appreciate the advice and link, it helps to have access to the documentation. Thanks for taking the time!
You are welcome.
bash vs zsh on terminal