On 6/9/07, mark david mcCreary <mdm(_at_)one-man-isp(_dot_)com> wrote:
The shell script knows the value of the variables in the procmail
recipe.
Yet when the shell script modifies the value of a variable, it does not
get
passed back up to the procmail recipe. That is, the procmail recipe
only
knows the original value, before the shell script was called.
Is there a way to change that behavior ?
No. The variables are placed in what's called the "process
environment" for passing from procmail to the shell script. This is
an operating-system-level construct and it's not shared; a new process
gets a *copy* of its parent's environment, and all changes made by the
new process occur in the copy where the parent can't see them. This
is basic unix process model stuff: no shared memory unless parent and
child are explicitly programmed to know where to look for it, which is
not possible for generic tools like procmail and a shell.
If you want to get data back into procmail you have to (for one
example) have the shell script write it to standard output where
procmail can read it.
____________________________________________________________
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