Class: CreateRepositories

Inherits:
ActiveRecord::Migration
  • Object
show all
Includes:
Six::Dbmanager::Migrate
Defined in:
lib/six-updater-web/db/migrate/20090826185820_create_repositories.rb

Constant Summary collapse

FIELDS =
["repository", "server"]

Class Method Summary collapse

Methods included from Six::Dbmanager::Migrate

included

Class Method Details

.downObject



14
15
16
17
# File 'lib/six-updater-web/db/migrate/20090826185820_create_repositories.rb', line 14

def self.down
  drop_table :repositories
  six_join(FIELDS, :down)
end

.upObject



5
6
7
8
9
10
11
12
# File 'lib/six-updater-web/db/migrate/20090826185820_create_repositories.rb', line 5

def self.up
  create_table :repositories do |t|
    t.string :url

    t.timestamps :lock_version => false
  end
  six_join(FIELDS, :up)
end