diff --git a/bin/pyenv-virtualenv b/bin/pyenv-virtualenv index 382f13a..90aa712 100755 --- a/bin/pyenv-virtualenv +++ b/bin/pyenv-virtualenv @@ -157,7 +157,7 @@ build_package_ez_setup() { http get "${EZ_SETUP_URL}" fi } 1> "${ez_setup}" - pyenv-exec python "${ez_setup}" ${EZ_SETUP_OPTS} 1>&2 || { + pyenv-exec python -s "${ez_setup}" ${EZ_SETUP_OPTS} 1>&2 || { echo "error: failed to install setuptools via ez_setup.py" >&2 return 1 } @@ -175,14 +175,14 @@ build_package_get_pip() { http get "${GET_PIP_URL}" fi } 1> "${get_pip}" - pyenv-exec python "${get_pip}" ${GET_PIP_OPTS} 1>&2 || { + pyenv-exec python -s "${get_pip}" ${GET_PIP_OPTS} 1>&2 || { echo "error: failed to install pip via get-pip.py" >&2 return 1 } } build_package_ensurepip() { - pyenv-exec python -m ensurepip 2>/dev/null || build_package_get_pip "$@" || return 1 + pyenv-exec python -s -m ensurepip 2>/dev/null || build_package_get_pip "$@" || return 1 } prepare_requirements() { diff --git a/test/pip.bats b/test/pip.bats index 909a0f3..b7337d5 100644 --- a/test/pip.bats +++ b/test/pip.bats @@ -26,7 +26,7 @@ unstub_pyenv() { stub pyenv-prefix " : echo '${PYENV_ROOT}/versions/${PYENV_VERSION}'" stub pyenv-prefix " : echo '${PYENV_ROOT}/versions/${PYENV_VERSION}'" stub pyenv-exec "pyvenv ${PYENV_ROOT}/versions/venv : echo PYENV_VERSION=\${PYENV_VERSION} \"\$@\";mkdir -p \${PYENV_ROOT}/versions/venv/bin" - stub pyenv-exec "python -m ensurepip : echo PYENV_VERSION=\${PYENV_VERSION} \"\$@\";touch \${PYENV_ROOT}/versions/venv/bin/pip" + stub pyenv-exec "python -s -m ensurepip : echo PYENV_VERSION=\${PYENV_VERSION} \"\$@\";touch \${PYENV_ROOT}/versions/venv/bin/pip" remove_executable "3.4.1" "virtualenv" create_executable "3.4.1" "pyvenv" @@ -36,7 +36,7 @@ unstub_pyenv() { assert_success assert_output <