Paul Bartlett replied to Philip Guenther's advice,
| Do I interpret you
| correctly that if I just add the '?' to the (only) condition as you
| have it above, then procmail will not log it if egrep does not find a
| match in the $USERLIST file, which is an anticipated condition
| according to the recipe below?
That's it, pretty much. Then Paul gave more details on the code in question:
| # check whether $WHOFROM value is in # $USERLIST file
| :0 wc
| | egrep -is $WHOFROM $USERLIST
|
| # subrecipe to execute if egrep _does_ find a match
| :0 a
| { big nesting block }
|
| # subrecipe to execute if egrep _does_not_ find a match
| :0 E
| { another big nesting block }
You can write it like this, and procmail will not comment on a bad exit
code from egrep (unless you have VERBOSE on, in which case procmail will
log "No match" for the egrep condition if it exits with failure):
:0
* ? egrep -is "$WHOFROM" $USERLIST
{ first big nesting block }
:0E
{ second big nesting block }