mirror of
https://github.com/pyenv/pyenv-virtualenv.git
synced 2025-11-11 21:13:52 -05:00
renamed virtualenv() to venv()
This commit is contained in:
@@ -100,14 +100,14 @@ http_get_wget() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
version() {
|
version() {
|
||||||
local version="$(virtualenv --version 2>/dev/null || true)"
|
local version="$(venv --version 2>/dev/null || true)"
|
||||||
echo "pyenv-virtualenv ${PYENV_VIRTUALENV_VERSION} (virtualenv ${version:-unknown})"
|
echo "pyenv-virtualenv ${PYENV_VIRTUALENV_VERSION} (virtualenv ${version:-unknown})"
|
||||||
}
|
}
|
||||||
|
|
||||||
usage() {
|
usage() {
|
||||||
# We can remove the sed fallback once pyenv 0.2.0 is widely available.
|
# We can remove the sed fallback once pyenv 0.2.0 is widely available.
|
||||||
pyenv-help virtualenv 2>/dev/null || sed -ne '/^#/!q;s/.//;s/.//;1,4d;p' < "$0"
|
pyenv-help virtualenv 2>/dev/null || sed -ne '/^#/!q;s/.//;s/.//;1,4d;p' < "$0"
|
||||||
virtualenv --help 2>/dev/null || true
|
venv --help 2>/dev/null || true
|
||||||
[ -z "$1" ] || exit "$1"
|
[ -z "$1" ] || exit "$1"
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -120,7 +120,7 @@ virtualenv_is_pyvenv() {
|
|||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
virtualenv() {
|
venv() {
|
||||||
if virtualenv_is_pyvenv; then
|
if virtualenv_is_pyvenv; then
|
||||||
pyenv-exec pyvenv "$@"
|
pyenv-exec pyvenv "$@"
|
||||||
else
|
else
|
||||||
@@ -281,7 +281,7 @@ STATUS=0
|
|||||||
# change to cache directory to reuse them between invocation.
|
# change to cache directory to reuse them between invocation.
|
||||||
mkdir -p "${PYENV_VIRTUALENV_CACHE_PATH}"
|
mkdir -p "${PYENV_VIRTUALENV_CACHE_PATH}"
|
||||||
cd "${PYENV_VIRTUALENV_CACHE_PATH}"
|
cd "${PYENV_VIRTUALENV_CACHE_PATH}"
|
||||||
virtualenv $QUIET $VERBOSE "${VIRTUALENV_OPTIONS[@]}" "${VIRTUALENV_PATH}" || STATUS="$?"
|
venv $QUIET $VERBOSE "${VIRTUALENV_OPTIONS[@]}" "${VIRTUALENV_PATH}" || STATUS="$?"
|
||||||
|
|
||||||
# Create symlink of `python' bound for actual executable
|
# Create symlink of `python' bound for actual executable
|
||||||
# TODO: remove this if virtualenv doesn't really need this
|
# TODO: remove this if virtualenv doesn't really need this
|
||||||
|
|||||||
Reference in New Issue
Block a user