]> git.openstreetmap.org Git - rails.git/blob - config/preinitializer.rb
Remove ancient (and unused) composite_primary_keys gem
[rails.git] / config / preinitializer.rb
1 require 'yaml'
2
3 config = YAML.load_file(File.expand_path("../application.yml", __FILE__))
4 env = ENV['RAILS_ENV'] || 'development'
5
6 ENV.each do |key,value|
7   if key.match(/^OSM_(.*)$/)
8     Object.const_set(Regexp.last_match(1).upcase, value)
9   end
10 end
11
12 config[env].each do |key,value|
13   unless Object.const_defined?(key.upcase)
14     Object.const_set(key.upcase, value)
15   end
16 end