procmail
[Top] [All Lists]

Re: setting a in procmail thats used by a shell script

1996-06-01 09:09:44
Gumbie <gumbie(_at_)sunspot(_dot_)tiac(_dot_)net> writes:
  Is there away to set a variable from within procmail so that when a 
shell script gets executed, that variable is available to the shell script?
 I think $ENV may be the answer but the man pages are not clear on it's 
usage...

Procmail exports all the variables you set in it to any programs executed
from it.

$ENV sounds like you're thinking of either perl's %ENV associative array
(accessed as $ENV{'variable name'}) or ksh/bash's $ENV for specifying a
file to read during startup.  Don't worry about them.  Just set your
variables in the script, like:

FOO = bar

then use them from the script like any other environment variable.

Philip Guenther


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