summaryrefslogtreecommitdiff
path: root/plugins/pyenv/pyenv.plugin.zsh
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/pyenv/pyenv.plugin.zsh')
-rw-r--r--plugins/pyenv/pyenv.plugin.zsh4
1 files changed, 4 insertions, 0 deletions
diff --git a/plugins/pyenv/pyenv.plugin.zsh b/plugins/pyenv/pyenv.plugin.zsh
index 48c8ffaf5..b5c9a7bd3 100644
--- a/plugins/pyenv/pyenv.plugin.zsh
+++ b/plugins/pyenv/pyenv.plugin.zsh
@@ -1,3 +1,7 @@
+# if there is a virtualenv already loaded pyenv should not be loaded
+# see https://github.com/ohmyzsh/ohmyzsh/issues/12589
+[[ -n ${VIRTUAL_ENV:-} ]] && return
+
pyenv_config_warning() {
[[ "$ZSH_PYENV_QUIET" != true ]] || return 0