> >  my @option_spec = ("config|c=s@",
> >                "mail-to|m=s@",
> > -              "tag|only-tag|r=s@",
> > +              "only-tag|tag|r=s@",
> >                "file-prefix|file-text|T=s", "user|u=s",
> I don't see any good reason for this reordering, but I included it
> anyhow.

That one is important (maybe I should have commented my changes :/),
because GetOpt uses the first alternative in $config afaics. So in
this case: $config{only-tag} (previously: $config{tag}).

&{$config{'only-tag'} won't be called if 'tag' is the first
alternative. Since you already used $config{tag} to store the option
values and $config{only-tags} as the callback, I just set 'only-tag'
as the first alternative.

-- 
Sylvain


Reply via email to