On Saturday 30 August 2003 14:15, Yorkshire Dave wrote:
> On Fri, 2003-08-29 at 14:50, Jason Stubbs wrote:
> > Hmmm....
> >
> > I've called the script notify and changed it as follows:
> >
> > #!/bin/sh
>
> This is probably a silly question but why not just script it straight
> into ~/.procmailrc?

Because I don't know procmail well enough - barely at all, actually - to be 
able to do it straight out. Also, I'd like to get the first x lines of the 
body into the notification message as well. If it's a short e-mail my 
girlfriend may not have to use the computer at all! ;-)

> Oh, and it makes sense to use formail to extract the relevant fields,
> that's what it's for.
> FROM=`formail -xFrom:`
> SUBJ=`formail -xSubject:`
> DATE=`formail -xDate:`

Hmmm. Sounds cleaner but I've only got one stdin. Wouldn't formail want to see 
the entire mail message or at least all of the headers? If so, how could I 
duplicate stdin for each field?

Regards,
Jason

--
[EMAIL PROTECTED] mailing list

Reply via email to