]> git.datanom.net - wpp.git/blame - db_downgrade.py
rm test access
[wpp.git] / db_downgrade.py
CommitLineData
047d4d29
MR
1#!flask/bin/python
2from migrate.versioning import api
3from config import SQLALCHEMY_DATABASE_URI
4from config import SQLALCHEMY_MIGRATE_REPO
5v = api.db_version(SQLALCHEMY_DATABASE_URI, SQLALCHEMY_MIGRATE_REPO)
6api.downgrade(SQLALCHEMY_DATABASE_URI, SQLALCHEMY_MIGRATE_REPO, v - 1)
7v = api.db_version(SQLALCHEMY_DATABASE_URI, SQLALCHEMY_MIGRATE_REPO)
8print('Current database version: ' + str(v))
This page took 0.027205 seconds and 5 git commands to generate.