etlmcrt(_at_)etlxdmx(_dot_)ericsson(_dot_)se ("Marc Rackett (ETLMCRT XB/VAC)")
wrote:
As the condition lines are ANDED, is there an elegant
solution to OR them?
To OR, you need to use the regular expression syntax for OR-ing (see the
procmailrc(5) man page for details):
* ^(To|Cc)(_dot_)*procmail(_at_)Informatik(_dot_)RWTH-Aachen(_dot_)DE
# Put all procmail information into procmail mailbox.
:0fwi:$MAILDIR/.lock
* ^To(_dot_)*procmail(_at_)Informatik(_dot_)RWTH-Aachen(_dot_)DE
* ^Cc(_dot_)*procmail(_at_)Informatik(_dot_)RWTH-Aachen(_dot_)DE
$MAILDIR/procmail
For To: and Cc:, it is best to use the following:
# fwi not needed as you're not piping to a program, and
# best to lock only the file being delivered to, not whole mail directory,
# so allow default lockfile by specifying only ":"
:0:
* ^TOprocmail(_at_)Informatik(_dot_)RWTH-Aachen(_dot_)DE
$MAILDIR/procmail
Personally I use the following for most mailing lists since I have
occasionally seen messages come _from_ mailing lists as well as going _to_
the list address (though I've never seen the procmail/smartlist lists
behave that way):
MAILDIR=$HOME/Mail
FROM="(Resent-)?(From|Sender):(.*[^a-zA-Z])?"
:0:
* $(^TO|^$FROM)mailing-list
mailing-list
-philip
____________________________________________________________ Philip Kizer ___
Texas A&M CIS Operating Systems Group, Unix ( 409.862.4120 )
pckizer(_at_)tamu(_dot_)edu
"Relying on the government to protect your privacy is like asking a peeping
tom to install your window blinds." -John Perry Barlow, EFF co-founder