mjn wrote:
When a message comes in, it is mangled to this:
FROM: "Mike Neuharth" <mjn(_at_)groupwise(_dot_)system(_dot_)com>
TO: mjn(_at_)umn(_dot_)edu
Subject: Random subject-Delegated
>>> username 12/02/03 14:51 >>>
txt txt txt txt txt txt txt txt txt txt
Things to note in the above text:
->The FROM address shows up as my account on the groupwise system and not
the /original/ sender.
->The "username" contained within the line starting ">>>" is the username
of the original sender.
->Subject has "-Delegated" appended to it by the Groupwise system
Something like
# Extract the username from the body
USERNAME=`(formail -I "" | cut -f 2 -d " ")`
# Replace the From: header
:0fhw
| formail -I "From: $USERNAME(_at_)groupwise(_dot_)system(_dot_)com"
should work (untested).
Stripping off fixed text from the subject line should be easier and you will
find various recipes doing just that.
--
Klaus Johannes Rusch
KlausRusch(_at_)atmedia(_dot_)net
http://www.atmedia.net/KlausRusch/
_______________________________________________
procmail mailing list
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail