bashrc & zshrc: check that we have pyenv before trying to apply it.

This commit is contained in:
Mikaela Suomalainen 2014-04-29 15:29:50 +03:00
parent 77c2a6f864
commit 0f301848ff
2 changed files with 7 additions and 2 deletions

3
bashrc
View File

@ -194,7 +194,10 @@ alias pyenv-install="cd ~;git clone https://github.com/yyuu/pyenv.git $PYENV_ROO
PATH=$PYENV_ROOT/bin:$HOME/.local/bin:$HOME/.local/sbin:$HOME/.local/games:$HOME/bin:$HOME/sbin:$HOME/games:$HOME/tmcbeans/bin:/opt/local/bin:/opt/local/sbin:/opt/local/games:/usr/local/bin:/usr/local/sbin:/usr/local/games:/bin:/sbin:/games:/usr/bin:/usr/sbin:/usr/games:$PATH PATH=$PYENV_ROOT/bin:$HOME/.local/bin:$HOME/.local/sbin:$HOME/.local/games:$HOME/bin:$HOME/sbin:$HOME/games:$HOME/tmcbeans/bin:/opt/local/bin:/opt/local/sbin:/opt/local/games:/usr/local/bin:/usr/local/sbin:/usr/local/games:/bin:/sbin:/games:/usr/bin:/usr/sbin:/usr/games:$PATH
# Apply pyenv changes. # Apply pyenv changes.
if [ -d "$PYENV_ROOT" ]; then
eval "$(pyenv init -)" eval "$(pyenv init -)"
fi
# "Changes" home directory without root. Uncomment both lines below this. # "Changes" home directory without root. Uncomment both lines below this.
#export HOME=<path to new home> #export HOME=<path to new home>

2
zshrc
View File

@ -137,7 +137,9 @@ alias pyenv-install="cd ~;git clone https://github.com/yyuu/pyenv.git $PYENV_ROO
PATH=$PYENV_ROOT/bin:$HOME/.local/bin:$HOME/.local/sbin:$HOME/.local/games:$HOME/bin:$HOME/sbin:$HOME/games:$HOME/tmcbeans/bin:/opt/local/bin:/opt/local/sbin:/opt/local/games:/usr/local/bin:/usr/local/sbin:/usr/local/games:/bin:/sbin:/games:/usr/bin:/usr/sbin:/usr/games:$PATH PATH=$PYENV_ROOT/bin:$HOME/.local/bin:$HOME/.local/sbin:$HOME/.local/games:$HOME/bin:$HOME/sbin:$HOME/games:$HOME/tmcbeans/bin:/opt/local/bin:/opt/local/sbin:/opt/local/games:/usr/local/bin:/usr/local/sbin:/usr/local/games:/bin:/sbin:/games:/usr/bin:/usr/sbin:/usr/games:$PATH
# Apply pyenv changes. # Apply pyenv changes.
if [ -d "$PYENV_ROOT" ]; then
eval "$(pyenv init -)" eval "$(pyenv init -)"
fi
# "Changes" home directory without root. Uncomment both lines below this. # "Changes" home directory without root. Uncomment both lines below this.
#export HOME=<path to new home> #export HOME=<path to new home>