[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Email header parser?



Hello!

On Sat, Apr 13, 2002 at 10:09:20AM +0300, Jarno Elonen wrote:
> Hi,
> 
> I'm building a set of scripts to archive email messages in a custom way.
> 
> Do you know of any better shell tools for extracting from, cc, subject etc. 
> >from the headers than procmail/formail?

look at http://cr.yp.to/mess822.html

...
> formail but would generate a shell script snippet that, when evaluated, sets 
> environment variables like $FROMNAME, $FROMADDRESS, $SUBJECT, $REPLYTO etc.

I think you'll have to script around to get it

suppose the messages is in "mess":

FROMNAME ?
FROMADDRESS=$(822field from < mess)
SUBJECT=$(822field < mess)
REPLYTO=$(822field reply-to < mess)


etc.

Best Regards,

     Jorge-León


-- 
To UNSUBSCRIBE, email to debian-isp-request@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org



Reply to: