From d15edd05770f0e4abae27070d2fcb25396e09cbe Mon Sep 17 00:00:00 2001 From: Sean Zeng Date: Thu, 15 Jan 2015 01:32:43 -0800 Subject: [PATCH] add support for pyenv-virtualenv --- modules/python/init.zsh | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/modules/python/init.zsh b/modules/python/init.zsh index da78ea79..b94ac2c5 100644 --- a/modules/python/init.zsh +++ b/modules/python/init.zsh @@ -45,6 +45,14 @@ if (( $+commands[virtualenvwrapper.sh] )); then source "$commands[virtualenvwrapper.sh]" fi +# Load pyenv-virtualenv into the shell session. +if (( $+commands[pyenv-virtualenv-init] )); then + # Disable the virtualenv prompt. + VIRTUAL_ENV_DISABLE_PROMPT=1 + + eval "$(pyenv virtualenv-init -)"; +fi + # # Aliases #