Ejemplo n.º 1
0
def action_extensions(params):
    from nailgun.logger import logger
    from nailgun.db.migration import action_migrate_alembic_extension
    from nailgun.extensions import get_all_extensions

    for extension in get_all_extensions():
        if extension.alembic_migrations_path():
            logger.info("Running command for extension {0}".format(extension.full_name()))
            action_migrate_alembic_extension(params, extension=extension)
        else:
            logger.info("Extension {0} does not have migrations. " "Skipping...".format(extension.full_name()))
Ejemplo n.º 2
0
def action_extensions(params):
    from nailgun.logger import logger
    from nailgun.db.migration import action_migrate_alembic_extension
    from nailgun.extensions import get_all_extensions

    for extension in get_all_extensions():
        if extension.alembic_migrations_path():
            logger.info('Running command for extension {0}'.format(
                extension.full_name()))
            action_migrate_alembic_extension(params, extension=extension)
        else:
            logger.info('Extension {0} does not have migrations. '
                        'Skipping...'.format(extension.full_name()))