Module: SettingsReader

Defined in:
lib/settings_reader.rb,
lib/settings_reader/reader.rb,
lib/settings_reader/version.rb,
lib/settings_reader/mixins/path.rb,
lib/settings_reader/configuration.rb,
lib/settings_reader/mixins/values.rb,
lib/settings_reader/resolvers/env.rb,
lib/settings_reader/resolvers/erb.rb,
lib/settings_reader/backends/abstract.rb,
lib/settings_reader/backends/yaml_file.rb,
lib/settings_reader/resolvers/abstract.rb

Overview

Flexible Settings reader with support of custom backends and value resolutions

Defined Under Namespace

Modules: Backends, Mixins, Resolvers Classes: Configuration, Error, Reader

Constant Summary collapse

VERSION =
'0.2.0'.freeze

Class Method Summary collapse

Class Method Details

.load(base_path = '') {|configuration| ... } ⇒ Object

Yields:

  • (configuration)


16
17
18
19
20
# File 'lib/settings_reader.rb', line 16

def self.load(base_path = '')
  configuration = SettingsReader::Configuration.new
  yield(configuration) if block_given?
  Reader.new(base_path, configuration)
end