Sha256: e60e662e99e01cf13bb096aa30ef3319f606074c22587b1835d547075bb5456b
Contents?: true
Size: 336 Bytes
Versions: 4
Compression:
Stored size: 336 Bytes
Contents
module YamlConf class Railtie < Rails::Railtie initializer "railtie.load_config" do begin ::CONFIG = YAML.load_file(File.join(Rails.root, "config", "config.yml"))[Rails.env].with_indifferent_access rescue Errno::ENOENT # config file does not exist yet ::CONFIG = {} end end end end
Version data entries
4 entries across 4 versions & 1 rubygems
Version | Path |
---|---|
yaml_conf-0.1.2 | lib/yaml_conf/railtie.rb |
yaml_conf-0.1.1 | lib/yaml_conf/railtie.rb |
yaml_conf-0.1.0 | lib/yaml_conf/railtie.rb |
yaml_conf-0.0.1 | lib/yaml_conf/railtie.rb |