Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(9)  |  Call(9)  |  Derive(0)  |  Import(0)

src/c/o/coaster-0.4.1/coaster/manage.py   coaster(Download)
    def run(self, args):
        if len(args) and not args[0].startswith('-'):
            manager.init_for(args[0])
        super(InitedMigrations, self).run(args[1:])
 
def drop(env):
    "Drops database tables"
    manager.init_for(env)
    manager.db.engine.echo = True
    if prompt_bool("Are you sure you want to lose all your data?"):
def create(env):
    "Creates database tables from sqlalchemy models"
    manager.init_for(env)
    manager.db.engine.echo = True
    manager.db.create_all()
def _make_context():
    manager.init_for('prod')
    return dict(app=manager.app, db=manager.db, init_for=manager.init_for, flask=flask)
 
 

src/c/o/coaster-HEAD/coaster/manage.py   coaster(Download)
    def run(self, args):
        if len(args) and not args[0].startswith('-'):
            manager.init_for(args[0])
        super(InitedMigrations, self).run(args[1:])
 
def drop(env):
    "Drop database tables"
    manager.init_for(env)
    manager.db.engine.echo = True
    if prompt_bool("Are you sure you want to lose all your data"):
def create(env):
    "Create database tables from sqlalchemy models"
    manager.init_for(env)
    manager.db.engine.echo = True
    manager.db.create_all()
def sync_resources(env):
    """Sync the client's resources with the Lastuser server"""
    manager.init_for(env)
    print "Syncing resources with Lastuser..."
    resources = manager.app.lastuser.sync_resources()['results']
    def _make_context():
        manager.init_for(env)
        return dict(app=manager.app, db=manager.db, init_for=manager.init_for, flask=flask)
    Shell(make_context=_make_context).run(no_ipython=no_ipython, no_bpython=no_bpython)