From 319000b448d675f6ea7ff3981b8f9e90f786eb6e Mon Sep 17 00:00:00 2001 From: Yamashita Yuu Date: Tue, 4 Jun 2013 17:35:23 +0900 Subject: [PATCH] pyenv-prefix returns wrong prefix if `system` is given in the middle of arguments. --- libexec/pyenv-prefix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libexec/pyenv-prefix b/libexec/pyenv-prefix index 1ee317bb..80c033a8 100755 --- a/libexec/pyenv-prefix +++ b/libexec/pyenv-prefix @@ -26,7 +26,7 @@ fi PYENV_PREFIX_PATHS=() for version in "${versions[@]}"; do if [ "$version" = "system" ]; then - PYTHON_PATH="$(pyenv-which python || true)" + PYTHON_PATH="$(PYENV_VERSION="${version}" pyenv-which python || true)" PYENV_PREFIX_PATH="${PYTHON_PATH%/*}" else PYENV_PREFIX_PATH="${PYENV_ROOT}/versions/${version}"