mirror of
https://github.com/pyenv/pyenv-virtualenv.git
synced 2025-11-08 11:33:55 -05:00
Use glob to check if the virtualenv is inside pyenv's prefix or not
This commit is contained in:
@@ -70,7 +70,7 @@ fi
|
||||
venv="${versions}"
|
||||
|
||||
# exit as success if some virtualenv outside from pyenv is already activated
|
||||
if [ -n "${VIRTUAL_ENV}" ] && [[ "${VIRTUAL_ENV}" == "${VIRTUAL_ENV#${PYENV_ROOT}/versions/}" ]]; then
|
||||
if [ -n "${VIRTUAL_ENV}" ] && [[ "${VIRTUAL_ENV}" != "${PYENV_ROOT}/versions/"* ]]; then
|
||||
if [ -z "${FORCE}" ]; then
|
||||
if [ -z "${QUIET}" ]; then
|
||||
echo "pyenv-virtualenv: virtualenv \`${VIRTUAL_ENV}' is already activated" 1>&2
|
||||
|
||||
Reference in New Issue
Block a user