class Conflate::Conflator
Attributes
config[RW]
path[RW]
Public Class Methods
new(path, config)
click to toggle source
Public: Initialize a new Conflator
path - Path the directory containing YAML configs (e.g., Rails.root.join(“config”)) config - Object to receive the config entries (e.g., Rails.application.config)
# File lib/conflate/conflator.rb, line 20 def initialize(path, config) self.path = path self.config = config end
Public Instance Methods
perform()
click to toggle source
Public: Process the configuration
# File lib/conflate/conflator.rb, line 26 def perform config_paths.each do |filename| Conflation.new(filename, config).apply end end
Private Instance Methods
config_paths()
click to toggle source
Private: The config files in the given path
Returns an Array of Strings containing paths
# File lib/conflate/conflator.rb, line 35 def config_paths Dir.glob(File.join path, "*.yml") end