Date: Wed, 16 Feb 2011 15:10:27 +0000
From: "N.J. Mann" <njm(_at_)njm(_dot_)me(_dot_)uk>
To: Anne Wilson <cannewilson(_at_)googlemail(_dot_)com>
Subject: Re: Can not get a filter recognised for one email source
Cc: procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)de
In message
<201102161233(_dot_)02064(_dot_)cannewilson(_at_)googlemail(_dot_)com>,
Anne Wilson (cannewilson(_at_)googlemail(_dot_)com) wrote:
On Wednesday 16 February 2011 12:13:34 N.J. Mann wrote:
In message
<201102160945(_dot_)00651(_dot_)cannewilson(_at_)googlemail(_dot_)com>,
Anne Wilson (cannewilson(_at_)googlemail(_dot_)com) wrote:
I get regular emails from one list, that always end up in my Inbox,
no matter
what I put in the recipes. At the moment these two recipes are in
place:
:0
* (^From|^To|^Subject): .*(Janome|embroidery|Embroidery|emblibrary|
empressmills)
${MAILDIR}.INBOX.Sewing/
:0
* ^From: .*Debra\@emblibrary.com
${MAILDIR}.INBOX.Sewing/
You have a space character in both recipes which should not be there.
Try:
* (^From|^To|^Subject):.*(Janome|embroidery|Embroidery|emblibrary|
and
* ^From:.*Debra\@emblibrary.com
OK, I've made the change. Now I wait a few days for the next message
:-)
Funny, though. All my recipes have a space there, and the others all
work.
I cut from my reply the header information you quoted, so here it is
again:
Received: from mail.emblibrary.com ([69.54.45.82]) (envelope-from
<Debra(_at_)emblibrary(_dot_)com>) from:
Debra(_at_)emblibrary(_dot_)com subject: Feather
Your Nest - New at Embroidery Library! X-Envelope-From:
Debra(_at_)emblibrary(_dot_)com
With a regexp of
^From: .*Debra
it will not match from: Debra(_at_)emblibrary(_dot_)com because it is
expecting
'from:' followed by one space, followed by one 'any' character,
followed by zero or more 'any' characters, followed by 'Debra', &c. If
you had either from: Debra or from:.*Debra it would match. This is
because there is only one character between from: and Debra and your
regexp is expecting at least two.
You are, quite simply, *WRONG* It is expecting 'from:' followed by one
space, followed by 'any character',*ZERO*OR*MORE* times, followed by the
literal string. ".*" matches _zero_or_more_ of 'any character'.
'*' (like '+' and '?') is only a "qualifier" of the preceding atom, it does
not specify any match in and of itself.
Don't believe me? See the procmailrc manpage, specifically the 'extended
regular expressions' sections, and *READ* the description of what "a*" means.
"Those of you who think you know it all are very annoying to those of us
who do." <grin>
____________________________________________________________
procmail mailing list Procmail homepage: http://www.procmail.org/
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)de
http://mailman.rwth-aachen.de/mailman/listinfo/procmail