Class: Alchemy::Config
- Inherits:
-
Object
- Object
- Alchemy::Config
- Defined in:
- lib/alchemy/config.rb
Class Method Summary collapse
-
.get(name) ⇒ Object
(also: parameter)
Returns the configuration for given parameter name.
-
.show ⇒ Object
Returns a merged configuration of the following files.
Class Method Details
.get(name) ⇒ Object Also known as: parameter
Returns the configuration for given parameter name.
10 11 12 |
# File 'lib/alchemy/config.rb', line 10 def get(name) show[name.to_s] end |
.show ⇒ Object
Returns a merged configuration of the following files
Alchemys default config: gems/../alchemy_cms/config/alchemy/config.yml
Your apps default config: your_app/config/alchemy/config.yml
Environment specific config: your_app/config/alchemy/development.config.yml
An environment specific config overwrites the settings of your apps default config, while your apps default config has precedence over Alchemys default config.
24 25 26 |
# File 'lib/alchemy/config.rb', line 24 def show @config ||= merge_configs!(alchemy_config, main_app_config, env_specific_config) end |