check pending migration

This commit is contained in:
Fábio C. Barrionuevo da Luz 2016-10-07 18:23:05 -03:00 committed by GitHub
parent 04a58d5b21
commit 9e2e78a474

View File

@ -16,3 +16,6 @@ cd project_name
# run the project's tests # run the project's tests
docker-compose -f dev.yml run django python manage.py test docker-compose -f dev.yml run django python manage.py test
# return non-zero status code if there are migrations that have not been created
docker-compose -f dev.yml run django python manage.py makemigrations --dry-run --check || { echo "ERROR: there were changes in the models, but migration listed above have not been created and are not saved in version control"; exit 1; }