]> git.openstreetmap.org Git - rails.git/blobdiff - db/migrate/001_create_osm_db.rb
Merge remote-tracking branch 'upstream/pull/1964'
[rails.git] / db / migrate / 001_create_osm_db.rb
index ddbfe259d613cbec2d589baa3319b8f2127c34a0..2edb658e4cc73611dc0d0e32be7bfec3855e5ec7 100644 (file)
@@ -1,6 +1,6 @@
 require "migrate"
 
-class CreateOsmDb < ActiveRecord::Migration
+class CreateOsmDb < ActiveRecord::Migration[5.0]
   def self.up
     create_table "current_nodes", :id => false do |t|
       t.column "id",        :bigint, :null => false
@@ -13,7 +13,7 @@ class CreateOsmDb < ActiveRecord::Migration
     end
 
     add_index "current_nodes", ["id"], :name => "current_nodes_id_idx"
-    add_index "current_nodes", %w(latitude longitude), :name => "current_nodes_lat_lon_idx"
+    add_index "current_nodes", %w[latitude longitude], :name => "current_nodes_lat_lon_idx"
     add_index "current_nodes", ["timestamp"], :name => "current_nodes_timestamp_idx"
 
     create_table "current_segments", :id => false do |t|
@@ -26,7 +26,7 @@ class CreateOsmDb < ActiveRecord::Migration
       t.column "timestamp", :datetime
     end
 
-    add_index "current_segments", %w(id visible), :name => "current_segments_id_visible_idx"
+    add_index "current_segments", %w[id visible], :name => "current_segments_id_visible_idx"
     add_index "current_segments", ["node_a"], :name => "current_segments_a_idx"
     add_index "current_segments", ["node_b"], :name => "current_segments_b_idx"
 
@@ -82,7 +82,7 @@ class CreateOsmDb < ActiveRecord::Migration
       t.column "timestamp", :datetime
     end
 
-    add_index "gps_points", %w(latitude longitude user_id), :name => "points_idx"
+    add_index "gps_points", %w[latitude longitude user_id], :name => "points_idx"
     add_index "gps_points", ["user_id"], :name => "points_uid_idx"
     add_index "gps_points", ["gpx_id"], :name => "points_gpxid_idx"
 
@@ -109,7 +109,7 @@ class CreateOsmDb < ActiveRecord::Migration
     end
 
     add_index "gpx_files", ["timestamp"], :name => "gpx_files_timestamp_idx"
-    add_index "gpx_files", %w(visible public), :name => "gpx_files_visible_public_idx"
+    add_index "gpx_files", %w[visible public], :name => "gpx_files_visible_public_idx"
 
     create_table "gpx_pending_files", :id => false do |t|
       t.column "originalname", :string
@@ -148,7 +148,7 @@ class CreateOsmDb < ActiveRecord::Migration
     end
 
     add_index "nodes", ["id"], :name => "nodes_uid_idx"
-    add_index "nodes", %w(latitude longitude), :name => "nodes_latlon_idx"
+    add_index "nodes", %w[latitude longitude], :name => "nodes_latlon_idx"
 
     create_table "segments", :id => false do |t|
       t.column "id",        :bigint
@@ -193,7 +193,7 @@ class CreateOsmDb < ActiveRecord::Migration
       t.column "sequence_id", :bigint, :null => false
     end
 
-    add_primary_key "way_segments", %w(id version sequence_id)
+    add_primary_key "way_segments", %w[id version sequence_id]
 
     create_table "way_tags", :id => false do |t|
       t.column "id",      :bigint, :default => 0, :null => false
@@ -202,7 +202,7 @@ class CreateOsmDb < ActiveRecord::Migration
       t.column "version", :bigint
     end
 
-    add_index "way_tags", %w(id version), :name => "way_tags_id_version_idx"
+    add_index "way_tags", %w[id version], :name => "way_tags_id_version_idx"
 
     create_table "ways", :id => false do |t|
       t.column "id",        :bigint, :default => 0, :null => false
@@ -212,7 +212,7 @@ class CreateOsmDb < ActiveRecord::Migration
       t.column "visible",   :boolean, :default => true
     end
 
-    add_primary_key "ways", %w(id version)
+    add_primary_key "ways", %w[id version]
     add_index "ways", ["id"], :name => "ways_id_version_idx"
   end