@@ -1,11 +1,11 | |||||
1 | class AddRepositoriesType < ActiveRecord::Migration |
|
1 | class AddRepositoriesType < ActiveRecord::Migration | |
2 | def self.up |
|
2 | def self.up | |
3 |
add_column :repositories, :type, :string |
|
3 | add_column :repositories, :type, :string | |
4 | # Set class name for existing SVN repositories |
|
4 | # Set class name for existing SVN repositories | |
5 | Repository.update_all "type = 'Subversion'" |
|
5 | Repository.update_all "type = 'Subversion'" | |
6 | end |
|
6 | end | |
7 |
|
7 | |||
8 | def self.down |
|
8 | def self.down | |
9 | remove_column :repositories, :type |
|
9 | remove_column :repositories, :type | |
10 | end |
|
10 | end | |
11 | end |
|
11 | end |
General Comments 0
You need to be logged in to leave comments.
Login now