procmail
[Top] [All Lists]

Re: How to pipe only if certain file exists?

2005-07-12 14:57:26
On Tue, Jul 12, 2005 at 11:10:14PM +0200, Dallman Ross wrote:
On Tue, Jul 12, 2005 at 04:05:41PM -0400, Jake Di Toro wrote:

:0wf
? test -x /usr/bin/qsf
| /usr/bin/qsf -sra

When I wrote my similar one without the f flag ("w" basically
always goes with "f"), I was not thinking that the qsf program
is intended to run as a filter, but rather that it would make
the delivery on its own.  If it's a filter and the mail should
return to procmail with something about it changed, then, yes,
we want the wf flags.  Good point.

-- 
dman

Hi,

Dallman's script works when I have the 'wf' flag (otherwise it didn't
work).

But Jake's doesn't seem to work.  In my log I get the entry:
    procmail: Extraneous filter-flag ignored
    procmail: Skipped "test -x /usr/bin/qsf"
    From otte(_at_)ucsc(_dot_)edu Tue Jul 12 14:47:28 2005
     Subject: test 2
       Folder: ?        
and a folder '?' is created and the message stored there.  I think I
have exactly what you suggested:
    :0wf
    ? test -x /usr/bin/qsf
    | /usr/bin/qsf -sra

Thanks,
Ric


____________________________________________________________
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