On Tue, 8 Jan 2002, Mark Stosberg wrote: > OTOH, I think MailPage is a good fit for CPAN-- it needs just bit of > code in an instance script to work, and you don't need a template file > to get going. If I was to provide a "default" template set to use with > Cascade, my 20+ template files would be somewhere in the depths of > /usr/local/lib/perl I suppose... which seems strange.
Actually, MailPage needs three templates but it comes with default ones that it squirls away in @INC. It's a sneaky trick, but it works! An alternative would be to ask the user where to put the templates at install time, then store that data someplace that your module will be able to get it - perhaps by generating a ::Config module. Or, if cleanliness is your goal, you can always inline the default template text into the module and load it with scalarref. > * Do large Perl apps really belong on CPAN? Large? No. Small and very configurable, leveraging most of their functionality from other CPAN modules? Yes. > * How do they fit currently? Not at all, with the lone exception of CGI::Application::MailPage, as far as I know. However, I don't think it has to stay that way. My sense is that there's a whole lot of duplication of effort in CGI-land. If we can bite off small, reusable apps and package them as configurable CGI::Applications then I think we'll go a long way towards saving the world. > [ I suppose this has really become more of a CPAN question now, rather > than CGI::App. :) ] Indeed. But, at least for me personally, an important one. In a couple months I'll be writing a chapter about this exact topic - using CGI::Application to package CGI apps for distribution on CPAN. So bring it on! -sam --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]