SPUG: Procmail
marlin
marlin at 3hats.com
Mon May 29 14:34:29 CDT 2000
Thanks to those who replied so far.
Here is log entry when I send mail to the address in question...
***************************
procmail:
1 at /home/pws_sales_inv/Procmail/grabdata.pl line 9, <> chunk 26.
>From marlingreene at mindspring.com Mon May 29 11:44:25 2000
Subject: inventory
Folder:
/var/spool/mail/pws_sales_inv 1098
***************************
The ref to "line 9, <> chunk 26" is at the "while (<>)"
statement in the Perl script. What seems to be happening is
that the script hiccups at the <> and the mail then is
delivered to standard box for the address.
Any ideas?
Marlin
Andrew Sweger wrote:
>
> Check your procmail log to see if the pattern is matching at all (is it
> calling the script). Then you can workout if the script is working
> correctly or not. Note that once the message is piped off to your perl
> script, it is considered delivered and no further processing of the
> original message is done in the procmail recipe (unless you set up some
> other settings in the recipe). Also, the output of the perl script is not
> considered by procmail for any processing (can't remember if there's an
> option to enable that, however). Otherwise, your recipe below should work
> as advertised.
>
> On May 26, 2000 @ 6:01pm, marlin wrote:
>
> > Anybody out there know how to make Procmail pipe an imcoming email
> > (with "inventory" as subject) to a Perl script?
> >
> > Here's what doesn't work...
> >
> > :0
> > * ^Subject:.*inventory
> > | /path/to/script.pl
> >
> > Pseudo-Perl is like this...
> >
> > while (<>) {
> > $msg .= $_;
> > }
> > process $msg;
>
> --
> Andrew Sweger <andy at n2h2.com> | N2H2, Incorporated
> Systems Architect | 900 Fourth Avenue, Suite 3400
> Advanced Technologies Division | Seattle WA 98164-1059
> v=206.336.2947 f=206.336.1541 | http://www.n2h2.com/
>
> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
> POST TO: spug-list at pm.org PROBLEMS: owner-spug-list at pm.org
> Seattle Perl Users Group (SPUG) Home Page: http://www.halcyon.com/spug/
> For Subscriptions, Email to majordomo at pm.org: ACTION spug-list EMAIL
> Replace ACTION by subscribe or unsubscribe, EMAIL by your Email address
--
3 Hats Design
INTERNET PRINT ILLUSTRATION
5201 15 Ave NW
Suite 220
Seattle, WA 98107
206.784.1641 phone
206.784.2231 fax
marlin at 3hats.com
http://www.3hats.com
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
POST TO: spug-list at pm.org PROBLEMS: owner-spug-list at pm.org
Seattle Perl Users Group (SPUG) Home Page: http://www.halcyon.com/spug/
For Subscriptions, Email to majordomo at pm.org: ACTION spug-list EMAIL
Replace ACTION by subscribe or unsubscribe, EMAIL by your Email address
More information about the spug-list
mailing list