in reply to Pod::ToDemo

I'd suggest sticking to POD but going a step further: extract =begin file foo.pl / =end file POD sections. It would then be Pod::Archive or some such. Could even have =begin uufile to include binary files, such as textures used in an SDL demo.

I also dislike the semantics of useing the POD file to extract. I'd prefer to have to run it as in something like perl `perldoc -l SDL::Tutorial`. Pod::Archive should then probably check $0 to find the file to extract from, and it should probably take at least a commandline option to pass a destination path.

Musing on, I could imagine Pod::Archive as a generic way to package miscellaneous files with a script or module; in that case it should actually have an API and only do the selfextractor magic when asked to, maybe as in use Pod::Archive qw(:selfextractor);.

Hmm. This is big. I don't know if you want to go there. And I'd like to try my hand at it myself, as it'd be something novel and really useful to "christen" my still empty CPAN directory with. It would probably be very neat to have for a number of projects out there (how to distribute extraneous misc files along with a script's distribution tarball was a repeated question on the Gtk2-Perl list), and relying on POD would be robust, unlike the source filter in Inline::Files.

Makeshifts last the longest.

Replies are listed 'Best First'.
Re: Re: Pod::ToDemo
by chromatic (Archbishop) on Dec 28, 2003 at 05:21 UTC

    I like your ideas, but agree they're getting ahead of my intentions for this module. Pod::Archive sounds like a good idea.

    In the meantime, I'm uploading this now as Pod::ToDemo. It's worth considering whether to extract the demo from POD sections; maybe the next version will do that.