Fun with App::Prove::Plugin

Eric Wilhelm scratchcomputing at gmail.com
Tue Feb 3 08:47:52 GMT 2009


# from Steve Purkis
# on Tuesday 03 February 2009 00:23:

>In the last case, I'm assuming the plugin could add it's own cmdline  
>params, to be parsed by GetOptions.  Yes, I know the plugin hasn't  
>even been loaded at this point.  I was thinking it might be possible  
>to pre-load plugins (or at least, plugins' cmdline parsing options),  
>which would involve scanning for available plugins, and making several
>   fancy guesses after parsing the cmdline opts about which plugins to
> load finally.

I just shipped Getopt::Base, which tries to cover a lot of what I've 
wanted from my option parser in the last few years.  Of possible 
interest in this case is the ability to cleanly stop the option 
parsing, set values in a results object, and possibly to add options as 
you go.  That does require that something trigger the pause/load of the 
parsing/plugin, but supporting svn-like modal option processing is on 
the todo list.  For an example, see the config-file loading of 
Getopt::AsDocumented.

--Eric
-- 
If the collapse of the Berlin Wall had taught us anything, it was that
socialism alone was not a sustainable economic model.
--Robert Young
---------------------------------------------------
    http://scratchcomputing.com
---------------------------------------------------


More information about the tapx-dev mailing list