lib/confidential/railtie.rb in confidential-0.0.5 vs lib/confidential/railtie.rb in confidential-0.0.6
- old
+ new
@@ -1,10 +1,10 @@
module Confidential
class Railtie < Rails::Railtie
-
+
config.before_configuration do
- confidential_file = Rails.root.join('config', 'confidential.yml')
- if File.exist? confidential_file and envs = YAML.load(File.read(confidential_file))
+ confidential_file = Rails.root.join('config', 'confidential.yml')
+ if File.exist? confidential_file and envs = YAML.load(File.read(confidential_file))
envs.each { |key, value| ENV[key] = value }
end
end
end