procmail
[Top] [All Lists]

Re: Can Procmail read from a file?

1999-04-12 17:28:07
"Randy James" <rjames(_at_)mathworks(_dot_)com> writes:
Are there any conventions within procmail to read text in from a file, or
compare variables to a file?
Anything file related would be helpful..

There's no direct way to read a file of arbitrary data into procmail.
If you can arrange for the contents of the file to be in the form of
a variable assignment then you can can just use INCLUDERC to perform
that assignment.  For general file contents you'll need to use shell
commands, either to perform the needed operations directly:

        :0
        * ? grep $whatever $somefile
        whatever

or to read the contents into a variable using var:

        VAR = `cat file`


Philip Guenther

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