load pyenv when it exists

This commit is contained in:
Inhji 2020-02-10 08:20:36 +01:00
parent cef5c729a4
commit c5875e623c
1 changed files with 5 additions and 3 deletions

View File

@ -39,8 +39,10 @@ prompt pure
eval $( dircolors -b $DOTFILES/config/zsh/dircolors.zsh )
# Pyenv
export PATH="/home/inhji/.pyenv/bin:$PATH"
eval "$(pyenv init -)"
eval "$(pyenv virtualenv-init -)"
if [[ -d $HOME/.pyenv ]]; then
export PATH="$HOME/.pyenv/bin:$PATH"
eval "$(pyenv init -)"
eval "$(pyenv virtualenv-init -)"
fi