]> git.lizzy.rs Git - cheatdb.git/commitdiff
Add migration
authorrubenwardy <rw@rubenwardy.com>
Tue, 29 May 2018 17:29:14 +0000 (18:29 +0100)
committerrubenwardy <rw@rubenwardy.com>
Tue, 29 May 2018 17:29:14 +0000 (18:29 +0100)
migrations/versions/aa6d21889d22_.py [new file with mode: 0644]

diff --git a/migrations/versions/aa6d21889d22_.py b/migrations/versions/aa6d21889d22_.py
new file mode 100644 (file)
index 0000000..f219f7d
--- /dev/null
@@ -0,0 +1,34 @@
+"""empty message
+
+Revision ID: aa6d21889d22
+Revises: b254f55eadd2
+Create Date: 2018-05-29 18:28:28.540416
+
+"""
+from alembic import op
+import sqlalchemy as sa
+
+
+# revision identifiers, used by Alembic.
+revision = 'aa6d21889d22'
+down_revision = 'b254f55eadd2'
+branch_labels = None
+depends_on = None
+
+
+def upgrade():
+    # ### commands auto generated by Alembic - please adjust! ###
+    op.alter_column('user', 'password',
+               existing_type=sa.VARCHAR(length=255),
+               nullable=True,
+               existing_server_default=sa.text("''"))
+    # ### end Alembic commands ###
+
+
+def downgrade():
+    # ### commands auto generated by Alembic - please adjust! ###
+    op.alter_column('user', 'password',
+               existing_type=sa.VARCHAR(length=255),
+               nullable=False,
+               existing_server_default=sa.text("''"))
+    # ### end Alembic commands ###