Gnus development mailing list
 help / color / mirror / Atom feed
From: Steinar Bang <sb@dod.no>
To: ding@gnus.org
Subject: Re: Has anyone created code for reply to author on yahoogroups?
Date: Sun, 21 Sep 2014 14:44:19 +0200	[thread overview]
Message-ID: <871tr5b0t8.fsf@dod.no> (raw)
In-Reply-To: <87a969fjw3.fsf@dod.no>

>>>>> Steinar Bang <sb@dod.no>:
>>>>> lee <lee@yun.yagibdah.de>:


>> Other than that, you could pipe the mails through a perl script that
>> fixes the headers. 

> That might be an idea... thanks for the heads up.  My yahoogroups'
> filtering already has subject tag stripping in them.
[snip!]
> I use dovecot with procmail(*) for mail filtering, so I would just put
> the fix in there.

Ok, now I've fixed the Yahoogroups.

I changed this:
 :0
 * ^TO_my-mailing-list@(intl.)?(e[Gg]roups|yahoogroups).com
 {
         :0 Afhw
         | /bin/sed -e "s/\[my-mailing-list\] //g"
 }

into this:
 :0
 * ^TO_my-mailing-list@(intl.)?(e[Gg]roups|yahoogroups).com
 {
         :0 Afhw
         | /usr/bin/perl -ne "s/(^From: \".+) \[my-mailing-list\]\" .*/\1\"/ig; s/(^From: \")'([^']+)'/\1\2/g;s/ ([A-za-z0-9.]+@[A-za-z0-9.]+)\"/\" <\1>/g;s/(^From: .*)\"([A-za-z0-9.]+@[A-za-z0-9.]+)\"/\1<\2>/g; if (/^Subject: /) {s/\[my-mailing-list\] //ig;} print"
 }

> (*) I know it's old, ancient actually, but it works and setting up mail
>     filtering is boring...

Speaking of ancient, my .procmailrc file also have this recipe, dating
back to the late ninties, but last touched in May of 2014, because of
the Android email client:
 #
 # Fix Subject RE/SV/AW line for MSExchange/MSMail/MSOutlook
 # Also fix Subject field for Norwegian android mailer ("Vedr").
 # No X-Mailer field to rely on, unfortunately!
 # Remove MSE quotes of type "'Real Name'"
 #
 :0 fhw
 | /usr/bin/perl -ne "s/\?[Ww]indows-1252\?/?iso-8859-1?/g; s/^(Subject:)\s+(S[Vv]:\s*|AW:\s*|Ad:\s*|Vedr:\s*|R[eE](\(\d+\))?:\s*)+/\1 Re: /g;s/^(Subject:)\s+(=\?((iso|ISO)-8859-1|us-ascii)\?Q\?)((S[Vv]|AW|Ad|R[eE](\(\d+\))?)(:|=3[Aa])_*)+/\1 \2Re:_/g; s/\042\'([^\']*)\'\042/\042\1\042/g ; print"

(The answer to the question "How many ways are there to break an email
header?", seems to be "inifinitly many"...)




      reply	other threads:[~2014-09-21 12:44 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-09-07 20:20 Steinar Bang
2014-09-08  0:45 ` lee
2014-09-08  7:18   ` Steinar Bang
2014-09-08 20:25     ` lee
2014-09-09  5:16       ` Steinar Bang
2014-09-09  5:22       ` Steinar Bang
2014-09-21 12:44         ` Steinar Bang [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=871tr5b0t8.fsf@dod.no \
    --to=sb@dod.no \
    --cc=ding@gnus.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).