> How would I include the original message in the auto-reply recipe below?
> Thanks...
Turn the reply generation recipe into two parts: one to filter the
header into a reply, and one to filter the body.
> :0Bc
> * $ ? egrep -s -f $PMDIR/match.reject
> ! nobody
Instead of this:
> :0Ah
> | ($FORMAILZ -I"From " \
> -I"From: $FROMZ" -r \
> -A"Precedence: junk" \
> -I"Subject: Project Genesis Rejection";\
> cat $TEXTDR/reject) | $SENDMAILZ -oi -t
>
Use these:
:0Afh # form the reply
| formail -rt -I"From: $FROMZ" \
-A"Precedence: junk" \
-I"Subject: Project Genesis Rejections"
:0afb # form the body
| cat $TEXTDR/reject -
:0a # now feed reply to sendmail
! -t
The "a" flags tell procmail to process those recipes only if the
preceding recipes' actions succeeded (ie: first the "formail" must
succeed and then the "cat").
The "fh" flags mean "filter head"; the "fb" flags mean "filter body".
The second recipe above assumes that "reject" ends up saying something like:
...
Your original message follows:
========================== Original Message ===========================
The "-" on the "cat" says to read STDIN at this point, which is the body
being fed from procmail.
Hope this helps.
___________________________________________________________
Alan Stebbens <aks(_at_)sgi(_dot_)com> http://reality.sgi.com/aks