Gnus development mailing list
 help / color / mirror / Atom feed
From: Steinar Bang <sb@dod.no>
To: ding@gnus.org
Subject: Re: Reply-prefix ("Re:") default regex
Date: Sat, 15 Aug 2015 21:21:45 +0200	[thread overview]
Message-ID: <86d1yo1ho6.fsf@dod.no> (raw)
In-Reply-To: <87oai84w08.fsf@denknerd.org>

>>>>> Paul van der Walt <paul@denknerd.org>:

> I recently ran into an issue where a French speaker i was communicating
> with had "Re : ..." as their reply subject prefix (note the leading
> space before the colon).  This quickly ended up with us bouncing emails
> around with such lovely subject lines as "Re: Re : Re: Re : Re: ...", et
> cetera, ad infinitum.  This phenomenon, of surrounding certain
> punctuation marks with extra spaces, turns out to be A Thing™ in French
> writing [0].  I discovered that by making a very small modification to
> the term `message-subject-re-regexp`, the problem was solved for me,
> locally (it's in my configuration files ATM).  But since this might be
> something that's useful to others, i threw a patch together, attached.

On a side note I have solved this outside of Gnus in procmail with this in my
.procmailrc:

#
# 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"

As this regular expression shows there seems to be a great deal of
creativity when it comes to messing up subject headers.  Everything
matched here has been encountered in the wild.




      parent reply	other threads:[~2015-08-15 19:21 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <87si7l4ndw.fsf@denknerd.org>
2015-08-15 11:43 ` Paul van der Walt
2015-08-15 15:51   ` Peter Münster
2015-08-15 16:48     ` [PATCH] message.el (message-subject-re-regexp): More liberal regex Paul van der Walt
2016-02-07  2:52       ` Lars Ingebrigtsen
2015-08-16  3:52     ` Reply-prefix ("Re:") default regex Eric Abrahamsen
2015-08-15 19:21   ` 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=86d1yo1ho6.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).