Created
July 2, 2015 07:24
-
-
Save tripleee/a74d5e3f05b1cf5c673b to your computer and use it in GitHub Desktop.
activate function for virtualenv
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Add this to your .bash_profile or similar | |
activate () | |
{ | |
test -d "$1" && test -r "$1/bin/activate" && . "$1/bin/activate" && return; | |
echo "activate: $1 does not look like a valid virtualenv" 1>&2; | |
return 1 | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment