"""Add bitbucket build trigger type

Revision ID: 313179799c8b
Revises: 37c47a7af956
Create Date: 2015-04-30 15:52:33.388825

"""

# revision identifiers, used by Alembic.
revision = '313179799c8b'
down_revision = '37c47a7af956'

from alembic import op
import sqlalchemy as sa


def upgrade(tables):
  op.bulk_insert(tables.buildtriggerservice, [{'id': 3, 'name': 'bitbucket'}])


def downgrade(tables):
  op.execute(
    tables.buildtriggerservice.delete()
    .where(tables.buildtriggerservice.c.name == op.inline_literal('bitbucket'))
  )
