Browse Source

display virtualenv's help message on '--help'

pull/3/merge
Yamashita Yuu 11 years ago
parent
commit
5b357d2862
1 changed files with 3 additions and 0 deletions
  1. +3
    -0
      bin/pyenv-virtualenv

+ 3
- 0
bin/pyenv-virtualenv View File

@ -3,6 +3,8 @@
# Summary: Create a Python virtualenv using the pyenv-virtualenv plugin # Summary: Create a Python virtualenv using the pyenv-virtualenv plugin
# #
# Usage: pyenv virtualenv [VIRTUALENV_OPTIONS] <version> <virtualenv-name> # Usage: pyenv virtualenv [VIRTUALENV_OPTIONS] <version> <virtualenv-name>
# pyenv virtualenv --version
# pyenv virtualenv --help
# #
PYENV_VIRTUALENV_VERSION="20130307" PYENV_VIRTUALENV_VERSION="20130307"
@ -69,6 +71,7 @@ version() {
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"
pyenv-exec python "${VIRTUALENV}" --help 2>/dev/null || true
[ -z "$1" ] || exit "$1" [ -z "$1" ] || exit "$1"
} }

Loading…
Cancel
Save