<reponame>JayDoubleu/backend<gh_stars>1-10
"""Model tweaks for github users

Revision ID: f2<PASSWORD>
Revises: a<PASSWORD>
Create Date: 2022-01-26 15:57:34.870992

"""
from alembic import op
import sqlalchemy as sa


# revision identifiers, used by Alembic.
revision = 'f2cdc<PASSWORD>'
down_revision = 'a<PASSWORD>49<PASSWORD>c9'
branch_labels = None
depends_on = None


def upgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    op.add_column('githubaccount', sa.Column('user', sa.Integer(), nullable=False))
    op.add_column('githubaccount', sa.Column('login', sa.String(), nullable=True))
    op.add_column('githubaccount', sa.Column('avatar_url', sa.String(), nullable=True))
    op.create_index(op.f('ix_githubaccount_user'), 'githubaccount', ['user'], unique=False)
    op.create_foreign_key(None, 'githubaccount', 'flathubuser', ['user'], ['id'])
    # ### end Alembic commands ###


def downgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    op.drop_constraint(None, 'githubaccount', type_='foreignkey')
    op.drop_index(op.f('ix_githubaccount_user'), table_name='githubaccount')
    op.drop_column('githubaccount', 'avatar_url')
    op.drop_column('githubaccount', 'login')
    op.drop_column('githubaccount', 'user')
    # ### end Alembic commands ###

"""Model tweaks for github users

Revision ID: f2<PASSWORD>
Revises: a<PASSWORD>
Create Date: 2022-01-26 15:57:34.870992

"""
from alembic import op
import sqlalchemy as sa


# revision identifiers, used by Alembic.
revision = 'f2cdc<PASSWORD>'
down_revision = 'a<PASSWORD>49<PASSWORD>c9'
branch_labels = None
depends_on = None


def upgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    op.add_column('githubaccount', sa.Column('user', sa.Integer(), nullable=False))
    op.add_column('githubaccount', sa.Column('login', sa.String(), nullable=True))
    op.add_column('githubaccount', sa.Column('avatar_url', sa.String(), nullable=True))
    op.create_index(op.f('ix_githubaccount_user'), 'githubaccount', ['user'], unique=False)
    op.create_foreign_key(None, 'githubaccount', 'flathubuser', ['user'], ['id'])
    # ### end Alembic commands ###


def downgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    op.drop_constraint(None, 'githubaccount', type_='foreignkey')
    op.drop_index(op.f('ix_githubaccount_user'), table_name='githubaccount')
    op.drop_column('githubaccount', 'avatar_url')
    op.drop_column('githubaccount', 'login')
    op.drop_column('githubaccount', 'user')
    # ### end Alembic commands ###
Model tweaks for github users  Revision ID: f2<PASSWORD> Revises: a<PASSWORD> Create Date: 2022-01-26 15:57:34.870992 # revision identifiers, used by Alembic. # ### commands auto generated by Alembic - please adjust! ### # ### end Alembic commands ### # ### commands auto generated by Alembic - please adjust! ### # ### end Alembic commands ###