Remove submodule, just put Dependencies in ./libs
This commit is contained in:
1 parent
2fb578d4de
commit
6888798ef6
541 files changed
+173394
-4
No files matched your search
@@ -0,0 +1,10 @@
|
||||
#!/usr/bin/env python
|
||||
from migrate.versioning.shell import main
|
||||
|
||||
{{py:
|
||||
_vars = locals().copy()
|
||||
del _vars['__template_name__']
|
||||
_vars.pop('repository_name', None)
|
||||
defaults = ", ".join(["%s='%s'" % var for var in _vars.iteritems()])
|
||||
}}
|
||||
main({{ defaults }})
|
||||
@@ -0,0 +1,29 @@
|
||||
#!/usr/bin/python
|
||||
# -*- coding: utf-8 -*-
|
||||
import sys
|
||||
|
||||
from sqlalchemy import engine_from_config
|
||||
from paste.deploy.loadwsgi import ConfigLoader
|
||||
|
||||
from migrate.versioning.shell import main
|
||||
from {{ locals().pop('repository_name') }}.model import migrations
|
||||
|
||||
|
||||
if '-c' in sys.argv:
|
||||
pos = sys.argv.index('-c')
|
||||
conf_path = sys.argv[pos + 1]
|
||||
del sys.argv[pos:pos + 2]
|
||||
else:
|
||||
conf_path = 'development.ini'
|
||||
|
||||
{{py:
|
||||
_vars = locals().copy()
|
||||
del _vars['__template_name__']
|
||||
defaults = ", ".join(["%s='%s'" % var for var in _vars.iteritems()])
|
||||
}}
|
||||
|
||||
conf_dict = ConfigLoader(conf_path).parser._sections['app:main']
|
||||
|
||||
# migrate supports passing url as an existing Engine instance (since 0.6.0)
|
||||
# usage: migrate -c path/to/config.ini COMMANDS
|
||||
main(url=engine_from_config(conf_dict), repository=migrations.__path__[0],{{ defaults }})
|
||||
Reference in new issue
Block a user