Skip to content

Instantly share code, notes, and snippets.

@dv
Created September 4, 2011 20:31
Show Gist options
  • Save dv/1193459 to your computer and use it in GitHub Desktop.
Save dv/1193459 to your computer and use it in GitHub Desktop.
Rails Custom Application Settings
# File 'config/initializers/settings.rb'
settings = YAML::load(ERB.new(IO.read(Rails.root + "config/settings.yml.erb")).result)
settings.merge(settings[Rails.env] || {})
::Settings = settings
# File 'config/settings.yml.erb'
deployed: <%= Time.now %>
admin:
name: David
mail: [email protected]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment