Sha256: 11abf4e8552fd4664e53afe24d08a6fa42023ad3e4cbd5bbeeb81b8f1056b090
Contents?: true
Size: 443 Bytes
Versions: 2
Compression:
Stored size: 443 Bytes
Contents
require "singleton" module Traquitana class Config include Singleton def initialize @configs = {} end def dir "traq" end def config "#{dir}/config.yml" end def default "#{File.dirname(File.expand_path(__FILE__))}/../config/default.yml" end def load(other=nil) @configs = YAML.load(File.read(other || config)) end def method_missing(meth) c = @configs[meth.to_sym] c ? c : "" end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
traquitana-0.0.11 | lib/config.rb |
traquitana-0.0.10 | lib/config.rb |