Hi,

I was bitten the other day by

    $ pick -list -sub foo last | cat; echo exit $?
    pick: no messages match specification
    0
    exit 0
    $ 

Namely, as described in pick(1)'s BUGS, if stdout isn't a tty then pick
lists the illegal message number 0 to cause errors to propogate, e.g.
through backticks back to rmm(1).

Effectively, I was doing

    foo `pick ...` `pick ...` `pick ...`

and wanted picks that found nothing to silently disappear;  my foo would
do the right thing with no arguments.

It occurred to me just now that we don't have a "none";  mh-sequence(5)
has "all" and Sequence-Negation but

    $ pick notall
    pick: bad message list notall

it seems Sequence-Negation doesn't apply to reserved word "all" and

    $ pick -seq foo all && pick -seq bar notfoo
    6003 hits
    pick: sequence foo full
    $ 

pick complains rather than effectively do

    mark -seq bar -del all

if sequence bar already exists.

If there was a "none" to pair "all" then pick could -list it instead of
the illegal 0 and it wouldn't be an error that propogates but a
reasonable action, e.g. the same as `scan none'.

Anyone know why the "0" route was chosen at the time?

Cheers, Ralph.

_______________________________________________
Nmh-workers mailing list
[email protected]
https://lists.nongnu.org/mailman/listinfo/nmh-workers

Reply via email to