scripts/reset_db.sh
changeset 416 265dbd81c451
parent 413 49b58b9b10a1
child 441 10f16121a46b
equal deleted inserted replaced
415:c631194cec2a 416:265dbd81c451
     1 #! /bin/bash
     1 #! /bin/bash
     2 
     2 
     3 sudo -u postgres dropdb pytask
     3 sudo -u postgres dropdb pytask
     4 sudo -u postgres createdb -O pytask pytask
     4 sudo -u postgres createdb -O pytask pytask
       
     5 rm -r pytask/profile/migrations/
       
     6 rm -r pytask/taskapp/migrations/
       
     7 ./bin/django schemamigration profile --initial
       
     8 ./bin/django schemamigration taskapp --initial
     5 ./bin/django syncdb
     9 ./bin/django syncdb
     6 ./bin/django migrate profile
    10 ./bin/django migrate profile
     7 ./bin/django migrate taskapp
    11 ./bin/django migrate taskapp
     8 ./bin/django loaddata sites_fixture.json 
    12 ./bin/django loaddata sites_fixture.json 
     9 
    13