Created
March 12, 2013 08:33
-
-
Save johanmeiring/5141180 to your computer and use it in GitHub Desktop.
Basic bash script to create migrations for all apps in a Django project. File to be placed in the root directory of the project. Requires South.
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
#!/bin/bash | |
for file in $(\ | |
find . -maxdepth 1 -type d | \ | |
egrep -v "\.$" | \ | |
sed -r 's/\.\///'); do | |
python manage.py schemamigration $file --auto | |
done | |
exit 0 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment