procmail
[Top] [All Lists]

Fixing RE: RE: RE:

2007-05-27 05:29:04
I'm pretty sure the idea of fixing "RE: RE: RE(3)" in
Subjects has been discussed a few times in the past.
The archives could be consulted.

In any case, though, someone wrote a couple of weeks ago about it 
and was not answered.  Here's a procmail-only answer that
doesn't need to recurse:

 SPACE = ' '
 TAB   = '      '
 WS    = $SPACE$TAB

 :0
 * $ ^Subject:([$WS]*RE([(][0-9]+[)])*:(.*\<)?\/[^R0-9$WS:].*
 | formail -I "Subject: RE: $MATCH"


The only thing I can see it doesn't quite do right is,
if there is a colon or series of colons between RE:'s
(without other letters) or at the beginning of the first
non-"RE(#):", it cuts them out too.

Basically, this stops cutting at the first non-"RE(#):",
then prepends one "RE: ".

Dallman


____________________________________________________________
procmail mailing list   Procmail homepage: http://www.procmail.org/
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail

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