Forum: Rails Engines development Misunderstanding init_engine.rb?

Announcement (2017-05-07): is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see and for other Rails- und Ruby-related community platforms.
807e34b31d5463a9ac05d41458a9e537?d=identicon&s=25 Al Evans (al-evans)
on 2006-05-24 14:44
(Received via mailing list)
It seems to me that the init_engine.rb file must not be getting
processed, or -- just as likely -- I'm misunderstanding something.

For example, in init_engine.rb:

module PSitsnotEngine
   module VERSION
     Major = 0 # change implies compatibility breaking with previous
     Minor = 1 # change implies backwards-compatible change to API
     Release = 0 # incremented with bug-fixes, updates, etc.

   # Configuration -- can be overridden in environment.rb
   config :max_output_size, 640
   config :max_cache_size, 1024
   config :cache_file_type, 'png'

Then, script/console:

 >> PSitsnotEngine.class
=> Module
 >> PSitsnotEngine::VERSION.class
NameError: uninitialized constant VERSION
         from /opt/local/lib/ruby/gems/1.8/gems/activesupport-1.3.1/
lib/active_support/dependencies.rb:123:in `const_missing'
         from (irb):2
 >> PSitsnotEngine.config :max_output_size
=> nil
 >> PSitsnotEngine::CONFIG
=> {}

What am I missing here? The "config" statements work find if I put
them in environment.rb.

					--Al Evans--
This topic is locked and can not be replied to.