Class: Wdmc::Config

Inherits:
Object
  • Object
show all
Defined in:
lib/wdmc/config.rb

Class Method Summary collapse

Class Method Details

.loadObject



6
7
8
9
10
11
12
13
14
# File 'lib/wdmc/config.rb', line 6

def self.load
  dotfile = File.join(ENV['HOME'], '.wdmc.yml')
  if File.exist?(dotfile)
    config = YAML.load_file(dotfile)
  else
    abort "Config not found #{dotfile}"
  end
  config
end