mirror of
https://github.com/pyenv/pyenv-virtualenv.git
synced 2025-11-12 13:33:52 -05:00
Add missing declaration of virtualenv_prefix to fix looking up executables from source version (#62)
This commit is contained in:
@@ -37,8 +37,12 @@ if [ ! -x "${PYENV_COMMAND_PATH}" ]; then
|
||||
if [ ! -f "${no_global_site_packages}" ]; then
|
||||
include_system_site_packages=1
|
||||
fi
|
||||
virtualenv_orig_prefix="$(find "${virtualenv_libpath}/" -maxdepth 2 -type f -and -name "orig-prefix.txt" 2>/dev/null | head -1)"
|
||||
if [ -f "${virtualenv_orig_prefix}" ]; then
|
||||
virtualenv_prefix="$(cat "${virtualenv_orig_prefix}" 2>/dev/null || true)"
|
||||
fi
|
||||
fi
|
||||
if [ -n "${include_system_site_packages}" ]; then
|
||||
if [ -n "${include_system_site_packages}" ] && [ -n "${virtualenv_prefix}" ]; then
|
||||
# virtualenv is created with `--system-site-packages`
|
||||
virtualenv_command_path="${virtualenv_prefix}/bin/${PYENV_COMMAND_PATH##*/}"
|
||||
if [ -x "${virtualenv_command_path}" ]; then
|
||||
|
||||
Reference in New Issue
Block a user