application_configuration 1.0.1 → 1.0.2

Sign up to get free protection for your applications and to get access to all the features.
@@ -29,12 +29,6 @@ module Application
29
29
 
30
30
  class << self
31
31
 
32
- # attr_reader :config_file_location
33
- #
34
- # def init_config
35
- #
36
- # end
37
-
38
32
  def method_missing(sym, *args)
39
33
  inst = Application::Configuration.instance
40
34
  # check to see if the configuration needs to be reloaded.
@@ -105,47 +99,10 @@ module Application
105
99
  @final_configuration_settings = {} # reset the configuration
106
100
 
107
101
  self.loaded_files.each do |lf|
102
+ puts "Loading Configuration Settings from file: #{lf}"
108
103
  load_file(lf)
109
104
  end
110
105
 
111
- # if it's rails:
112
- # if self.is_rails
113
- # # load the default set of configurations for the app.
114
- # settings.merge!(load_from_file("#{RAILS_ROOT}/config/application_configuration.yml"))
115
- # puts settings.inspect
116
- # begin
117
- # # load the specific environment configurations if they exist.
118
- # settings.merge!(load_from_file("#{RAILS_ROOT}/config/#{RAILS_ENV}_application_configuration.yml"))
119
- # puts settings.inspect
120
- # rescue Exception => e
121
- # end
122
- # end
123
-
124
- # @final_configuration_settings = settings
125
- #
126
- # self.final_configuration_settings.each_pair do |k,v|
127
- # k = k.to_s.downcase
128
- # # start a list of methods that need to be generated
129
- # # methods can't have :: in them so convert these to __.
130
- # e_meths = [k.gsub("::", "__")]
131
- # if k.match("::")
132
- # vars = k.split("::") # get the namespace and the method names
133
- # mod = vars.first # namespace
134
- # e_meths << mod # generate a method for the namespace
135
- # # create a new Namespace object for this name space and assign it to the final_configuration_settings hash.
136
- # self.final_configuration_settings[mod.to_s] = Application::Configuration::Namespace.new(mod.to_s)
137
- # # add an entry for the __ version of the key so our __ method can call it.
138
- # self.final_configuration_settings[e_meths.first] = v
139
- # end
140
- # # generate all the necessary getter methods
141
- # e_meths.each do |m|
142
- # eval %{
143
- # def #{m}
144
- # self.final_configuration_settings["#{m}"]
145
- # end
146
- # }
147
- # end
148
- # end
149
106
  @last_reload_time = Time.now
150
107
  end
151
108
 
@@ -2,4 +2,4 @@
2
2
  gem_name: application_configuration
3
3
  package: application_configuration
4
4
  project: magrathea
5
- version: 1.0.1
5
+ version: 1.0.2
metadata CHANGED
@@ -3,7 +3,7 @@ rubygems_version: 0.9.2
3
3
  specification_version: 1
4
4
  name: application_configuration
5
5
  version: !ruby/object:Gem::Version
6
- version: 1.0.1
6
+ version: 1.0.2
7
7
  date: 2007-09-17 00:00:00 -04:00
8
8
  summary: application_configuration
9
9
  require_paths: