Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I trying to change the Login Shell of Mac OS X Lion from bash to zsh. I see it is possible in Mac OS X Leopard (http://hints.macworld.com/article.php?story=20071025221744166) but for OS X Lion I can't find a way. I really hope it is possible to change the Login shell from bash to something else. I am not exactly sure where to look for.

share|improve this question
    
After changing shell to zsh, I still had to launch zsh manually. Logging out didn't help. I then changed zsh to the upmost login shell. Logged out and there it was. –  user107694 Dec 1 '11 at 16:06
1  
If nothing else, you can always modify the .bashrc to find and exec zsh. if [ -x /usr/local/bin/zsh ] ; then exec /usr/local/bin/zsh fi. Hint, when modifying shell startup scripts, make sure to keep a shell running and start up a new one in another window - if you break it you still have an easy place to fix it. –  Dan Pritts Sep 30 '13 at 13:23

3 Answers 3

up vote 33 down vote accepted

chsh -s /bin/zsh   

share|improve this answer
1  
I installed a newer version of zsh with Homebrew, which put zsh in /usr/local/bin/zsh. Unfortunately, chsh doesn't allow this, saying chsh: /usr/local/bin/zsh: non-standard shell. Daniel Beck's answer is a suitable solution in this case. –  adam_0 Feb 2 '13 at 19:20
11  
If you are getting problems with non-standard shells, I think you should be able to add /usr/local/bin/zsh to /etc/shells and it should solve that problem. –  Mike Meyers Feb 28 '13 at 10:57
7  
The homebrew zsh install info does actually recommend you to add it to /etc/shells: ==> Caveats To use this build of Zsh as your login shell, add it to /etc/shells. –  George Mar 19 '13 at 11:20

Funnily enough, the same method you link to in your question still works in OS X Lion. The only difference: The preference pane is named Users & Groups instead of Accounts.

enter image description here

share|improve this answer
    
ouhp. bummer. :| –  Idlecool Dec 1 '11 at 19:31
1  
Confirmed that this works in Mountain Lion, as well as working with "non-standard shells" that you might install yourself (or have Homebrew install). –  adam_0 Feb 2 '13 at 19:21
1  
Confirmed still working in 10.10 Yosemite. –  ecnepsnai Sep 8 at 3:44
    
right click on the username to bring up the menu containing "advanced options". That took me a couple of minutes to find. –  pdwalker Dec 16 at 12:37
    
@pdwalker Right, I wrote this answer on the assumption that you read the question (and clicked the link there, which describes how to do this except for the name of the preference pane). –  Daniel Beck Dec 16 at 15:30

Or:

sudo dscl . change /users/$USER UserShell /bin/bash /opt/local/bin/zsh
share|improve this answer
2  
Can you explain why this answers the question? –  ChrisF Nov 25 '12 at 10:55
    
Be sure to run this after brew install zsh. –  mmell Mar 11 at 16:04

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.