menu
書いてる野郎
orebike@gmail.com
Mac OSX 10.7 Lion で Terminal を zsh に変更する方法。
Lionのターミナルでzshを使う方法。というかログインした時の標準シェルを変更する方法。
システム環境設定のユーザー&グループ(User & Groups)を選ぶ
鍵をクリックして設定を変更可能にする
ユーザーのリストの変更したいユーザーを右クリックして詳細オプションを変更する
Login shell をzshに変更する
以上!
まず現状のApple版のzshのバージョンを見る
$ zsh --version zsh 4.3.11 (i386-apple-darwin11.0)
インストール予定のbrew版を見る
$ brew info zsh zsh 4.3.17
ということでちょっと新しいのだ
brew版のzshを入れる
$ brew install zsh
/usr/local/bin/zsh
としてインストールされる。
インストール終了後
To use this build of Zsh as your login shell, add it to /etc/shells. If you have administrator privileges, you must fix an Apple miss configuration in Mac OS X 10.7 Lion by renaming /etc/zshenv to /etc/zprofile, or Zsh will have the wrong PATH when executed non-interactively by scripts. Alternatively, install Zsh with /etc disabled: brew install --disable-etcdir zsh
なんと表示される
ログインシェルに使いたいなら/etc/shells
に追加せよ
# List of acceptable shells for chpass(1). # Ftpd will not allow users to connect who are not using # one of these shells. /bin/bash /bin/csh /bin/ksh /bin/sh /bin/tcsh /bin/zsh /usr/local/bin/zsh
追加した。
一応ここで再起動なんかしておく
コマンドドン
$ chsh -s /usr/local/bin/zsh
これでbrew版のzshが使えるようになった
まだ何か書いてある
もしお前が管理者権限を持っているならば、アップルの間違った設定を直すべきだ。/etc/zshenv
を/etc/zprofile
にリネームしろ・・・
と、ということでドン
$ sudo mv zshenv zprofile
これでいいのかな
2012-07-21