1
0
mirror of https://github.com/pyenv/pyenv.git synced 2025-11-17 07:43:46 -05:00

fixed to read multiple versions from PYENV_VERSION environment variable

This commit is contained in:
Yamashita Yuu
2012-09-07 19:16:42 +09:00
parent 34a4a532b2
commit 13122ca9bf
8 changed files with 69 additions and 42 deletions

View File

@@ -41,7 +41,7 @@ remove_from_path() {
}
IFS=: versions=($(pyenv-version-name))
PYENV_VERSION=("${versions[@]}")
IFS=: PYENV_VERSION="${versions[*]}"
PYENV_COMMAND="$1"
if [ -z "$PYENV_COMMAND" ]; then
@@ -49,7 +49,7 @@ if [ -z "$PYENV_COMMAND" ]; then
exit 1
fi
for version in "${PYENV_VERSION[@]}"; do
for version in "${versions[@]}"; do
if [ "$version" = "system" ]; then
PATH="$(remote_from_path "${PYENV_ROOT}/shims")"
PYENV_COMMAND_PATH="$(command -v "$PYENV_COMMAND")"