1 from coprs import db
2 from coprs.logic import builds_logic
3 from commands.create_sqlite_file import create_sqlite_file_function
4 import click
5
6
7 @click.command()
8 @click.option(
9 "--alembic", "-f", "alembic_ini",
10 help="Path to the alembic configuration file (alembic.ini)",
11 required=True
12 )
14 """
15 Create the DB schema
16 """
17 create_sqlite_file_function()
18 db.create_all()
19
20
21 from alembic.config import Config
22 from alembic import command
23 alembic_cfg = Config(alembic_ini)
24 command.stamp(alembic_cfg, "head")
25