procmail
[Top] [All Lists]

Re: Filter first on From and then in Body

2005-05-17 12:03:15
On Tue, 17 May 2005 18:42:20 +0200 Sebastian Stein wrote:

I receive emails over a mailing list and I want to filter out some of them
based on the content in the body. That's what I tried so far:

:0:
* ^TO_uml-devel(_at_)lists(_dot_)sourceforge(_dot_)net
* B ?? "SVN commit"
L-uml-cvs

The recipe just for filtering the mailing list works, but the second rule
doesn't. I already tried many different variants, but without any luck.

You say the recipe for filtering list mail works but the *SECOND* rule
doesn't...

Uhhhh,  which one do you actually have FIRST in your .procmailrc file? If you
have it like this:

:0:
* ^TO_uml-devel(_at_)lists(_dot_)sourceforge(_dot_)net
L-uml

:0:
* ^TO_uml-devel(_at_)lists(_dot_)sourceforge(_dot_)net
* B ?? "SVN commit"
L-uml-cvs

Then all of your list mail will go to the L-uml mail folder BEFORE it ever
reaches the body check recipe. It's been delivered, it's no longer being
checked.

Reverse the order so the ones with the body check get pulled out and
delivered first. Those that don't get delivered by the body check will catch
the address only check. I use this by having default "fall through" recipes
for each of my addresses at the end of my .rc file to keep all the messages
that don't match any other recipes from all getting dumped into a single
inbox. They get sorted based on which of my addresses they were sent TO (or
CC). Most that get dumped in the final inbox default are spam that was BCCd
to me. 

Gerald


____________________________________________________________
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