plugins/virtualenv: use _command_exists
This commit is contained in:
@@ -1,3 +1,5 @@
|
||||
# shellcheck shell=bash
|
||||
#
|
||||
# make sure virtualenvwrapper is enabled if available
|
||||
|
||||
cite about-plugin
|
||||
@@ -5,8 +7,8 @@ about-plugin 'virtualenvwrapper and pyenv-virtualenvwrapper helper functions'
|
||||
|
||||
if _command_exists pyenv; then
|
||||
pyenv virtualenvwrapper
|
||||
else
|
||||
[[ `which virtualenvwrapper.sh` ]] && . virtualenvwrapper.sh
|
||||
elif _command_exists virtualenvwrapper.sh; then
|
||||
source virtualenvwrapper.sh
|
||||
fi
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user