1
0
mirror of https://github.com/pyenv/pyenv.git synced 2025-11-09 20:13:47 -05:00

Fix inverted condition for --altinstall of ensurepip (#255)

This commit is contained in:
Yamashita Yuu
2015-05-27 00:49:23 +09:00
parent fe934642c5
commit ed684c239c
2 changed files with 40 additions and 2 deletions

View File

@@ -1528,10 +1528,12 @@ build_package_get_pip() {
build_package_ensurepip() {
local ensurepip_opts
if [[ "$PYTHON_MAKE_INSTALL_TARGET" != *"altinstall"* ]]; then
# Install as `--altinstall` if the Python is installed as `altinstall` (#255)
if [[ "$PYTHON_MAKE_INSTALL_TARGET" == *"altinstall"* ]]; then
ensurepip_opts="--altinstall"
fi
"$PYTHON_BIN" -m ensurepip $ensurepip_opts 1>/dev/null 2>&1 || build_package_get_pip "$@" || return 1
# FIXME: `--altinstall` with `get-pip.py`
"$PYTHON_BIN" -m ensurepip ${ensurepip_opts} 1>/dev/null 2>&1 || build_package_get_pip "$@" || return 1
}
version() {