I do not like to write fish again and again when I start terminal. I want fish on by default.
the chsh
program will let you change your default shell. It will want the full path to the executable, so if your shell is fish
then it will want you to provide the output given when you type which fish
.
You'll see a line starting with "Shell:
". If you've never edited it, it most likely says "Shell: /bin/bash
". Replace that /bin/bash
path with the path to your desired shell.
heimdall:~ leeg$ dscl
Entering interactive mode... (type "help" for commands)
> cd /Local/Default/Users/
/Local/Default/Users > read leeg
[...]
UserShell: /bin/bash
/Local/Default/Users >
just change that value (with the write command in dscl
).
doesn't chsh exists under mac os?
if it does, just hit chsh.
Run the following code, for instance, to change your shell to Zsh
chsh -s /bin/zsh
Here's another way to do it:
Assuming you installed it with MacPorts, which can be done by doing:
sudo port install fish
Your shell will be located in /opt/local/bin/fish
.
You need to tell OSX that this is a valid shell. To do that, add this path to the end of the /etc/shells
file.
Once you've done this, you can change the shell by going to System Preferences -> Accounts. Click on the Lock to allow changes. Right-click on the account, and choose "Advanced Options...". In the "Login shell" field, add the path to fish.