Class: DbPatch::Migration::CreatePatchVersions

Inherits:
ActiveRecord::Migration
  • Object
show all
Defined in:
lib/db_patch/migration.rb

Class Method Summary collapse

Class Method Details

.downObject



14
15
16
# File 'lib/db_patch/migration.rb', line 14

def self.down
	drop_table :patch_versions
end

.upObject



5
6
7
8
9
10
11
12
# File 'lib/db_patch/migration.rb', line 5

def self.up
	create_table :patch_versions do |t|
		t.string :version
		t.timestamps
	end

	add_index :patch_versions, :version, :unique => true
end