Subject: Re: Procmail and Perl

From: [email-masked] (Robert W. Kerns)
Date: Thu, 29 Sep 1994 13:42:43 +0800

Lance A. Brown writes:
 > Ned Schumann <[email-masked]> writes:
 > 
 > > But when I substitute a Perl script (webmail) for 'date' I get...
 > 
 > > procmail: Assigning "LASTFOLDER= (formail -r -A "Precedence: bulk";\
 > >     (sh /h/webfiler/webmail)) | /usr/sbin/sendmail -t"
 >        ^^
 > > /h/webfiler/webmail: 2: Syntax error: word unexpected (expecting ")")
 > 
 > Your problem isn't perl.  You are calling bourne shell 'sh' and
 > telling it to run the script /h/webfiler/webmail, which is really a
 > perl script.  Remove the sh and just call run /h/webfiler/webmail and
 > it should work.

For this to work, he needs to sets the executable bit on the file with
chmod a+x /h/webfiler/webmail.  That's the simplest thing to do.  The
other thing is he could do is feed the script to perl directly.
I.e. (perl /h/webfiler/webmail).