Hi Al,
This is indeed the right place to post. First things first - what
versions of Ruby, Rails and the Engines plugin are you using?
The next thing to do when debugging this kind of stuff is stick 'puts'
lines at the top of files and start script/console or the webrick
server, so you can see what's being loaded when. FYI, the file
'init_engine.rb' will get loaded when you call Engines.start
:<engine_name>.
- james
On 5/25/06, Al Evans <[EMAIL PROTECTED]> wrote:
> (Sorry if this is not the right list -- I tried posting to engine-
> developers, but got no response.)
>
> 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, I have:
>
> module PSitsnotEngine
> module VERSION
> Major = 0 # change implies compatibility breaking with previous
> versions
> Minor = 1 # change implies backwards-compatible change to API
> Release = 0 # incremented with bug-fixes, updates, etc.
> end
>
> # Configuration -- can be overridden in environment.rb
> config :max_output_size, 640
> config :max_cache_size, 1024
> config :cache_file_type, 'png'
> end
>
> Then, I use 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 fine if I put
> them in environment.rb.
>
> --Al Evans--
>
>
> _______________________________________________
> engine-users mailing list
> [email protected]
> http://lists.rails-engines.org/listinfo.cgi/engine-users-rails-engines.org
>
--
* J *
~
_______________________________________________
engine-users mailing list
[email protected]
http://lists.rails-engines.org/listinfo.cgi/engine-users-rails-engines.org