Created
July 14, 2012 16:01
-
-
Save alexanderjulo/3111902 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
#!/bin/bash | |
# enable virtual environment for python | |
source venv/bin/activate | |
# hide changes that are not in this commit | |
git stash -q --keep-index | |
./manage.py test | |
RESULT=$? | |
# get non relevant changes back | |
git stash pop -q | |
# stop commit if tests fail | |
[ $RESULT -ne 0 ] && exit 1 | |
exit 0 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment