]> git.madduck.net Git - etc/mailfilter.git/blob - procmail/listquirks

madduck's git repository

Every one of the projects in this repository is available at the canonical URL git://git.madduck.net/madduck/pub/<projectpath> — see each project's metadata for the exact URL.

All patches and comments are welcome. Please squash your changes to logical commits before using git-format-patch and git-send-email to patches@git.madduck.net. If you'd read over the Git project's submission guidelines and adhered to them, I'd be especially grateful.

SSH access, as well as push access can be individually arranged.

If you use my repositories frequently, consider adding the following snippet to ~/.gitconfig and using the third clone URL listed for each project:

[url "git://git.madduck.net/madduck/"]
  insteadOf = madduck:

add riedel to immo
[etc/mailfilter.git] / procmail / listquirks
1 # for lists with a CC-all policy, add the M-F-T header if none exists. This
2 # should go together with mutt hooks to unset followup_to:
3 #
4 #   send-hook . 'set followup_to'
5 #   send-hook '~C git@vger\.kernel\.org' 'unset followup_to'
6 #
7 :0
8 * ! DEST ?? .
9 * ? echo "$EQ_TO" | $EGREP -qif $CONF/cclists
10 * ! ^Mail-Followup-To:
11 {
12   CORRESPONDENTS=`formail -cxTo: -xCc: -xFrom: | tr -s '\n' ,`
13   LOG="listquirks:  adding M-F-T header for message on list $EQ_TO$NL"
14   :0 fw
15   |$FORMAIL -A "Mail-Followup-To: $CORRESPONDENTS"
16   CORRESPONDENTS
17 }
18
19 # for lists that munge reply-to, let's get rid of it and instead add a M-F-T
20 # header with all correspondents.
21 #
22 :0 E
23 * ! DEST ?? .
24 * ? echo "$EQ_TO" | $EGREP -qif $CONF/replytolists
25 * $^Reply-To: $EQ_TO
26 {
27   CORRESPONDENTS=`formail -cxTo: -xCc: -xFrom: -xReply-To: | tr -s '\n' ,`
28   LOG="listquirks:  replacing Reply-To with M-F-T for message to list $EQ_TO$NL"
29   :0 fw
30   |$FORMAIL -I Reply-To: -A "Mail-Followup-To: $CORRESPONDENTS"
31   CORRESPONDENTS
32 }
33
34 # vim:ft=procmail