procmail
[Top] [All Lists]

Re: Assigning the body to a variable?

2001-04-17 07:27:41
Matt tried helping Randy,

| According to the man page, you can extract the body using formail.
| Perhaps try this (untested, of course!):
| 
| :0
| { THE_BODY=`|formail -I ""` }

Er, close.

(No :0 and no braces needed)

 THE_BODY=`formail -I ""`

or

 :0b
 THE_BODY=|cat

However, I'd like to see exactly how Randy plans to use the variable.  It
could be that the "B ??" modifier, the B flag, or the b flag already takes
care of what he wants.

For example, if he wants to feed the body to go.exe and append the result
to list.mail, he doesn't need to assign a variable at all, just change

| >     :0fhbw
| >     | go.exe >>list.mail

to

  :0bc: # no `c' if this is final delivery
  | go.exe >> list.mail

_______________________________________________
procmail mailing list
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail

<Prev in Thread] Current Thread [Next in Thread>