lib/configliere.rb in configliere-0.0.5 vs lib/configliere.rb in configliere-0.0.6
- old
+ new
@@ -1,23 +1,19 @@
require 'configliere/core_ext'
require 'configliere/param'
+require 'configliere/define'
+require 'configliere/config_file'
module Configliere
- # Where to load params given only a symbol
- DEFAULT_CONFIG_FILE = ENV['HOME']+'/.configliere.yaml' unless defined?(DEFAULT_CONFIG_FILE)
- # Where to load params given a bare filename
- DEFAULT_CONFIG_DIR = ENV['HOME']+'/.configliere' unless defined?(DEFAULT_CONFIG_DIR)
- #
- #
# delegates to Configliere::Param
def self.new *args, &block
Configliere::Param.new *args, &block
end
- ALL_MIXINS = [:define, :encrypted, :env_var, :config_file, :commandline, :config_block]
+ ALL_MIXINS = [:define, :config_file, :commandline, :encrypted, :env_var, :config_block]
def self.use *mixins
- mixins = ALL_MIXINS if mixins.include?(:all)
+ mixins = ALL_MIXINS if mixins.include?(:all) || mixins.empty?
mixins.each do |mixin|
require "configliere/#{mixin}"
end
end
end