procmail
[Top] [All Lists]

Behaviour Modification for unwanted CC's

2003-06-24 21:14:53
At 20:31 2003-06-24 -0700, Andrew Edelstein did say:
On Tue, Jun 24, 2003 at 09:29:18PM -0400, Dragoncrest wrote:
>         hehe.  I don't have a man file for that on my machine.  OH well,
> time to go googling.

Please see my signature below and STOP SENDING ME COPIES.

There's a solution to that problem. It's called "behaviour modification". It's a bit unorthodox, but it's worked reasonably well for me, esp. when someone asks "do you have any idea why I received two copies of the message I sent you?" "Yea, because you sent me two copies - one through the list, and one directly."

I have several reasons that unrequested carbons are unwelcome: one is the increased mail traffic (as if I really need to read two copies), another is that invariably, someone ELSE follows up to the list post and chooses to continue to [REPLY ALL] in their mail client, assuming that the previous recipients were copied for a reason (not!), and thirdly, I flag messages addressed directly to me, because the only reason I should be directly addressed on a message is because the message REQUIRES my attention. When it doesn't, it's a waste of my time.

So, here's the recipe (because, like, this is a procmail list <g>):

# After filing from-the-list copies of messages,
# aggressively ditch carbons and the like.
# (in actuality, I run this recipe just after a couple of lists with some
# rather dense participants, rather than all lists I participate on.
:0
* 9876543210^0 ^TO_regexp_for_the_list_in_question
* 9876543210^0 ^TO_regexp_for_another_list
{
        # argh - idiots insist on carbon-copying me even though I ask that
        # they do not.
        #
        # Fine.
        #
        # I'll send them a copy of their own crap, from themselves.  We add
        # an X-loop header so it doesn't cause us grief if it does loop back.
        # Set this sender to the original sender - it's THEIR message after
        # all.
        # My own email client rules will still highlight the message as To:
        # me, but I'll rest knowing that the twit who cc'd me gets a mystery
        # copy (or two) of their own crap.
        :0c
        * ! ^FROM_MAILER
        * ! ^X-Loop:[   ]*carbonated
        * ! SENDER ?? your_own_domain
        | formail -i "X-Loop: carbonated" -I "X-Envelope-To:" \
                -I "X-Envelope-To:" | $SENDMAIL -f$SENDER $SENDER

        # send an additional copy to the twit as well!
        # (just dupe this up several times if you'd like)
        :0Ac
        | formail -i "X-Loop: carbonated" -I "X-Envelope-To:" \
                -I "X-Envelope-To:" | $SENDMAIL -f$SENDER $SENDER

        # file the actual message away in a carbon file
        # (I personally store in gzip archives)
        :0:$TEMP/cc_list$LOCKEXT
        |gzip -9fc >> cc_list.gz
}

Obviously, several variables here are defined before this recipe is reached. If they don't make sense enough to you, check out my sandbox, which generally defines a number of the common ones I use.

---
 Sean B. Straw / Professional Software Engineering

 Procmail disclaimer: <http://www.professional.org/procmail/disclaimer.html>
 Please DO NOT carbon me on list replies.  I'll get my copy from the list.


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