Skip to content

Commit 61749bc

Browse files
committed
Add complete-time load to lazy loader.
1 parent 05549fe commit 61749bc

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

virtualenvwrapper_lazy.sh

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,4 +31,14 @@ function $venvw_name {
3131
done
3232
}
3333

34+
# Set up completion functions to virtualenvwrapper_load
35+
function virtualenvwrapper_setup_lazy_completion {
36+
if [ -n "$BASH" ] ; then
37+
complete -o nospace -F virtualenvwrapper_load cdvirtualenv cdsitepackages workon rmvirtualenv cpvirtualenv showvirtualenv
38+
elif [ -n "$ZSH_VERSION" ] ; then
39+
compctl -K virtualenvwrapper_load cdvirtualenv cdsitepackages workon rmvirtualenv cpvirtualenv showvirtualenv
40+
fi
41+
}
42+
3443
virtualenvwrapper_setup_lazy_loader
44+
virtualenvwrapper_setup_lazy_completion

0 commit comments

Comments
 (0)