Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'db/migrate/20130506095501_remove_project_id_from_key.rb')
-rw-r--r--db/migrate/20130506095501_remove_project_id_from_key.rb22
1 files changed, 0 insertions, 22 deletions
diff --git a/db/migrate/20130506095501_remove_project_id_from_key.rb b/db/migrate/20130506095501_remove_project_id_from_key.rb
deleted file mode 100644
index 6b794cfb5c1..00000000000
--- a/db/migrate/20130506095501_remove_project_id_from_key.rb
+++ /dev/null
@@ -1,22 +0,0 @@
-class RemoveProjectIdFromKey < ActiveRecord::Migration
- def up
- puts 'Migrate deploy keys: '
- Key.where('project_id IS NOT NULL').update_all(type: 'DeployKey')
-
- DeployKey.all.each do |key|
- project = Project.find_by(id: key.project_id)
- if project
- project.deploy_keys << key
- print '.'
- end
- end
-
- puts 'Done'
-
- remove_column :keys, :project_id
- end
-
- def down
- add_column :keys, :project_id, :integer
- end
-end