Created
December 9, 2014 19:18
-
-
Save dahlia/a430965d2756eb5bbcc9 to your computer and use it in GitHub Desktop.
Autoactivate 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
if [[ "$PWD" == "$PROJECT_HOME"* ]]; then | |
for project in "$WORKON_HOME/"*/; do | |
if [[ "$(cat $project/.project)" == "$PWD" ]]; then | |
source "$project"bin/activate | |
break | |
fi | |
done | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment