summaryrefslogtreecommitdiff
path: root/db/migrate/20151105094515_create_releases.rb
blob: 4b180a59486a36b10cabc9ccedc23e50e71fd1fb (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
# rubocop:disable all
class CreateReleases < ActiveRecord::Migration[4.2]
  DOWNTIME = false

  def change
    create_table :releases do |t|
      t.string :tag
      t.text :description
      t.integer :project_id

      t.timestamps null: true
    end

    add_index :releases, :project_id
    add_index :releases, [:project_id, :tag]
  end
end