procmail
[Top] [All Lists]

Re: Out of Plant Recipe help

1998-10-09 09:33:26
On Fri, Oct 09, 1998 at 09:21:51AM -0500, Todd Lindstrom wrote:

I am sick and tired of getting Email from people in my
company telling me that they are going to be out of the
plant on a given day.  For the most part I could care less.

My recipe is as follows

#OK - now I'm tired of all the out of plants I get 
:0
* ((^Subject:.*OOP) | (^Subject:.*out.of.plant))
|(formail -A "Subject: SPAM - OUT OF PLANT") | /usr/lib/sendmail -oi 
my_acct(_at_)my(_dot_)popserver(_dot_)com

You're trying to match too many spaces.  Not much will match on
" ^Subject:"...

Try this.

:0
* ^Subject:.*([^a-z]oop[^a-z]|out.of.plant)
|formail -A "Subject: SPAM - OUTTA PLANT" | /usr/lib/sendmail -oi 
your_acct(_at_)your(_dot_)popserver(_dot_)com

The [^a-z] keep the recipe from matching subjects such as
"Decommissioned troop transport sinks; two hundred rats dead"
and
"Oops, Todd, I just deleted your unix account!"

The subject added by the formail has been changed so just in case it 
loops back to your unix account, it won't be run through this recipe
again.  

Greg
-- 
Gregory S. Sutter                     Madness takes its toll.  
mailto:gsutter(_at_)pobox(_dot_)com              Please have exact change.
http://www.pobox.com/~gsutter/
PGP DSS public key 0x40AE3052

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