2016-11-01 00:17:54 -04:00
|
|
|
"""empty message
|
|
|
|
|
|
|
|
Revision ID: 0cd36ecdd937
|
|
|
|
Revises: None
|
|
|
|
Create Date: 2016-11-01 05:25:42.691768
|
|
|
|
|
|
|
|
"""
|
|
|
|
|
|
|
|
# revision identifiers, used by Alembic.
|
|
|
|
revision = '0cd36ecdd937'
|
|
|
|
down_revision = None
|
|
|
|
|
|
|
|
from alembic import op
|
|
|
|
import sqlalchemy as sa
|
|
|
|
|
|
|
|
|
|
|
|
def upgrade():
|
|
|
|
op.create_table('URL',
|
2024-09-27 11:39:18 -04:00
|
|
|
sa.Column('id', sa.Integer(), nullable=False),
|
|
|
|
sa.Column('url', sa.UnicodeText(), nullable=True),
|
|
|
|
sa.PrimaryKeyConstraint('id'),
|
|
|
|
sa.UniqueConstraint('url'))
|
2016-11-01 00:17:54 -04:00
|
|
|
op.create_table('file',
|
2024-09-27 11:39:18 -04:00
|
|
|
sa.Column('id', sa.Integer(), nullable=False),
|
|
|
|
sa.Column('sha256', sa.String(), nullable=True),
|
|
|
|
sa.Column('ext', sa.UnicodeText(), nullable=True),
|
|
|
|
sa.Column('mime', sa.UnicodeText(), nullable=True),
|
|
|
|
sa.Column('addr', sa.UnicodeText(), nullable=True),
|
|
|
|
sa.Column('removed', sa.Boolean(), nullable=True),
|
|
|
|
sa.PrimaryKeyConstraint('id'),
|
|
|
|
sa.UniqueConstraint('sha256'))
|
2016-11-01 00:17:54 -04:00
|
|
|
|
|
|
|
|
|
|
|
def downgrade():
|
|
|
|
op.drop_table('file')
|
|
|
|
op.drop_table('URL')
|