On Wed, 28 Aug 2002, James C. McMaster (Jim) wrote:
Several misguided mailing lists add a "[identifier] " token to their
Subject: headers to make their lists "easy" to use. One list I am on
just added a very long id, which is annoying enough I want to get rid of
it with procmail.
Something like this should do it:
RE=
:0
* ^Subject: \/(Re: |\[[^]]+\] )+
* MATCH ?? ()\/(Re: )
{ RE=$MATCH }
:0fhW
* ^Subject: (Re: |\[[^]]+\] )+\/.*
| formail -I"Subject: $RE$MATCH"
You can probably figure out how to adjust it for UAs that do stupid things
like 'Re[2]:' and other prefixes like "Fw:" or "(Fwd)".
_______________________________________________
procmail mailing list
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail