zshでPATHが通せなかった話
zshでPATHを通したかった。
なるほど。つまり
~/.zshenv に
path=( ~/.gem/ruby/2.2.0/bin $path )
とか書いてやればいい。
私の環境では動きませんでした。
source ~/.zshenv とかしてやれば通るので書き間違いではなさそう。
echo $pathでどこで変わったのか探していくと、不穏なものを発見
/etc/zsh/zprofile
emulate sh -c 'source /etc/profile'
/etc/profile
# /etc/profile #Set our umask umask 022 # Set our default path PATH="/usr/local/sbin:/usr/local/bin:/usr/bin" export PATH # Load profiles from /etc/profile.d if test -d /etc/profile.d/; then for profile in /etc/profile.d/*.sh; do test -r "$profile" && . "$profile" done unset profile fi # Source global bash config if test "$PS1" && test "$BASH" && test -r /etc/bash.bashrc; then . /etc/bash.bashrc fi # Termcap is outdated, old, and crusty, kill it. unset TERMCAP # Man is much better than us at figuring this out unset MANPATH
んー……zprofileコメントアウトしてumaskとpathだけzshenvに移しておきましょうか。