procmail
[Top] [All Lists]

RE: removing duplicates based upon an excerpt from the msg. body

2006-02-11 12:15:13

MD5=`formail -I '' | head -400 | md5sum | head -c 32`

Correction: the 'head -400', should read 'head -c 400', because I'm
interested in only the first 400 characters (not lines) of the message.
Complete, corrected recipe follows:

:0
* PUNDIT ?? ^^YES^^
{
MD5=`formail -I '' | head -c 400 | md5sum | head -c 32`
FROM_ADDR=`echo "$REALLY_FROM" |
           sed -e 
's/.*\(\<[A-Za-z_(_dot_)+0-9]*(_at_)[A-Za-z0-9_(_dot_)]*\).*/\1/'`
:0:
* !? echo "Message-ID: $MD5-$FROM_ADDR" | formail -D 5000
$HOME/.pundit.cache
pundit-mail
:0E
/dev/null
}




____________________________________________________________
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