Deb Lewis
2006-Jun-12 19:49 UTC
[Masterview-devel] Latest round of changes in initializer mechanism
Redid all directory path refs to be relative to the app root (no more cleverness about assuming app/views context w/in rails app for specifying template dirs): config_dir_path, template_src_dir_path, and template_dst_dir_path are relative paths from config.root_path. If you need to specify location outside the app''s root directory scope, there''s abs-path setter methods. Default template src path changed from app/views/masterview to app/masterview - pulls up a level, now a parallel dir structure alongside the default target dir of app/views. Add logger config settings: config.logger to configure log4r or std ruby logger; config.log_level to specify log level. This turns out to be nice, makes it easy to configure/disable debug logging. Tested with both log4r and logger to make sure this works for both flavors. [not quite sure yet about default loc for auto-adding app directives to the load path - need to test whether something like lib/master/view/directives or lib/mv-directives works as desired; not sure that app/masterview/directives is right place, don''t want directives code muddled under template src dir - would be ok if we made app/masterview/templates the default src dir, but then dir levels aren''t symmetric with target app/views] doc/configuration.html updated; examples of settings files updated to provided commented-out template with all the options. [still to do: reorganize top-level index.html to link to config doc] Unit tests for config settings updated; new code tested in rails app in my working copy. Still to do: test clean install as rails plugin and via gem into new, empty rails app to do full life-cycle test. In order to activate in the main integration, I need to submit updated init.rb (mostly comment fixes for the rdoc) and lib/masterview.rb (changes the way things are done to hook in the initializer). There''ll also be README and RELEASE_NOTES updates, of course. ~ Deb