@app.command()
def create(name,
           dependencies=('d', [], 'migration dependencies'),
           prefix_date=('p', False, 'prefix migration name with date'),
           **opts):
    repo = opts['repo']
    deps = map(repo.get, dependencies)

    if prefix_date:
        name = date.today().strftime('%Y%m%d-') + name

    path = op.join(repo.path, name)
    try:
        os.mkdir(path)
    except OSError as e:
        if e.errno == 17:
            abort('directory %s already exists' % path)
        raise

    with open(op.join(path, 'migration.ini'), 'w') as f:
        f.write('[nomad]\n')
        f.write('dependencies = %s\n' % ', '.join(d.name for d in deps))
    with open(op.join(path, 'up.sql'), 'w') as f:
        f.write('-- SQL ALTER statements for database migration\n')
Return a flat top window.
dataset/ETHPy150Open piranha/nomad/nomad/__init__.py/create--crossover with--dataset/ETHPy150Open scipy/scipy/scipy/signal/windows.py/flattop