getopt-long [was: -t output]

David Relson relson at osagesoftware.com
Wed Jul 30 20:12:40 CEST 2003


At 12:33 PM 7/30/03, Przemyslaw Brojewski wrote:
>On Wed, Jul 30, 2003 at 09:33:22AM -0400, David Relson wrote:
> > At 09:24 AM 7/30/03, Przemyslaw Brojewski wrote:
> >
> > >It's either single terse format or scripts should have some way of
> > >overriding
> > >bogofilter's config file. Time for getopt-long?
> >
> > Przemyslaw,
> >
> > A script can create and use its own config file.  However there's no easy
> > way to combine a site config with a script config.
> >
> > getopt-long is a possibility.  Would you like to take on the task??
> >
>
>I would. Thank you for te invitation. But there are few reasons that
>I should not:
>- I never used getopt before in an application that would accept more
>   then 5 switches.
>- My programming experience is limited to few years of scripting, mainly
>   in Perl. There happend one apache module years ago, for version 1.2.x,
>   and there was few C-based modules for Perl 5.0, but that's it.
>   Those things were put together in haste and ugly.
>- I'm going for a hoilday this Friday, and won't be back till 25th of
>   September.
>
>Anyway, If you are not yet discuraged, I'm going to pretty-print
>bogofilter sources and get familiar with them, while I am away from
>civilisation. My goal would be to add support for something like:
>
>    --config '<a line of config file here>'
>
>This option would be executed after default config file has been
>processed, so Pi's script could do:
>
>bogofilter --config 'terse_format = %1.1c %f' \
>            --config 'spamicity_tags = Yes, No, Unsure' \
>            <some other arguments>
>
>and be happy with whatever user defaults.
>
>
>Przemyslaw Brojewski.
>
>---------------------------------------------------------------------
>FAQ: http://bogofilter.sourceforge.net/bogofilter-faq.html
>To unsubscribe, e-mail: bogofilter-unsubscribe at aotto.com
>For summary digest subscription: bogofilter-digest-subscribe at aotto.com
>For more commands, e-mail: bogofilter-help at aotto.com





More information about the Bogofilter mailing list