Whilst helping a colleague get to grips with shells on his Mac, including seeing what shells are out there: -
cat /etc/shells
# Ftpd will not allow users to connect who are not using
# one of these shells.
/bin/bash
/bin/csh
/bin/dash
/bin/ksh
/bin/sh
/bin/tcsh
/bin/zsh
and switching between them: -
chsh -s /bin/dash hayd
Changing shell for hayd.
Password for hayd:
chsh -s /bin/bash hayd
Changing shell for hayd.
Password for hayd:
we also discussed the "nagware" that includes in macOS to get us to switch away from the oh-so-ancient Bash 3.2: -
bash --version
Copyright (C) 2007 Free Software Foundation, Inc.
namely: -
java version "1.8.0_311"
Java(TM) SE Runtime Environment (build 1.8.0_311-b11)
Java HotSpot(TM) 64-Bit Server VM (build 25.311-b11, mixed mode)
The default interactive shell is now zsh.
To update your account to use zsh, please run `chsh -s /bin/zsh`.
For more details, please visit https://support.apple.com/kb/HT208050.
Using this: -
How to hide the ‘default interactive shell is now zsh’ message in Terminal on macOS
as source, I coached him to add: -
export BASH_SILENCE_DEPRECATION_WARNING=1
to ~/.bash_profile
and now we just see this: -
java version "1.8.0_311"
Java(TM) SE Runtime Environment (build 1.8.0_311-b11)
Java HotSpot(TM) 64-Bit Server VM (build 25.311-b11, mixed mode)
No comments:
Post a Comment