procmail
[Top] [All Lists]

Re: Recipe question

2003-12-18 15:32:15
On Mon, 15 Dec 2003 12:54:25 -0800
PSE-L(_at_)mail(_dot_)professional(_dot_)org (Professional Software 
Engineering) wrote:

^To:*joe([a-g]|[j-z])*

which, with my limited understanding of RegExp says:

anything beginning with "joe" but continuing with either letters a-g *or*
j-z.

Not with the * (zero or more) wildcard count it won't.  Further, the :* at 
the beginning means zero or more colons, and doesn't provide you with any 
support for the whitespace you probably meant to catch.

You want something more like:

* ^To:.*\<joe[a-gj-z][^ ]*(_at_)sympatico\(_dot_)ca

Note that the two character ranges can be put into a single character class 
bracket, eliminating the need for the parenthesis and or construct, and 
since just ONE of these will cause the address to be identified as not 
yours.  I extend with with a not space out to the @ and your domain, and 
allow for whatever before the name and a wordbreak there as well.

If the ONLY address you have is joehill, then you missed the 'i' which 
should be in the expression, and also, you could replace [a-gj-z] with 
[^hi] instead.

Sorry for the late reply, I got that flu bug, it's one nasty SOB. 

Anyhow, now that I'm back up and wasting my time in front of this box again...

Over 200 e-mails waiting for me, only 6 spam. Between Mailfilter on the
frontlines and Procmail lying in wait, things are goin' great, esp with the
rules/recipes you've helped me with.

Again, many thanks, and have a happy $HOLIDAY!

-- 
JoeHill ++ ICQ # 280779813
Registered Linux user #282046
Homepage: www.orderinchaos.org
+++++++++++++++++++++++++++
"In this possibly terminal phase of human existence, democracy and freedom are
more than just ideals to be valued - they may be essential to survival...."--
Noam Chomsky

_______________________________________________
procmail mailing list
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail

<Prev in Thread] Current Thread [Next in Thread>