procmail
[Top] [All Lists]

Re: subject mungeing and header question

1999-04-07 12:35:31
You can only have one action line.  What you actually need to do
is to combine the two rules in some way.  Here are two examples:

--- example 1
:0fhw
* ^TOrennlist
* ^Subject: *\[911\] \/.*
|formail -I"Subject: $MATCH"

:0:
* ^TOrennlist
porsche
---

--- example 2
:0
* ^TOrennlist
{
    :0fhw
    * ^Subject: *\[911\] \/.*
    | formail -I"Subject: $MATCH"

    :0:
    porsche
}
---

These both have exactly the same effect.
---
Russell Heilling   -   Technical Manager   -   NetDirect Internet Ltd
Tel: +441812937000 email:russellh(_at_)netdirect(_dot_)net(_dot_)uk Fax: 
+441812936000
   "That which doesn't kill you will make you bitter and cynical"
----- Original Message -----
From: Chuck Campbell <campbell(_at_)neosoft(_dot_)com>
To: Philip Guenther <guenther(_at_)gac(_dot_)edu>; 
<campbell(_at_)neosoft(_dot_)com>
Cc: <procmail(_at_)informatik(_dot_)rwth-aachen(_dot_)de>
Sent: Wednesday, April 07, 1999 7:09 PM
Subject: Re: subject mungeing and header question


On Tue, Apr 06, 1999 at 05:01:44PM -0500, Philip Guenther wrote:
Chuck Campbell <campbell(_at_)neosoft(_dot_)com> writes:

How can I get procmail to strip this when handling mail from this list?

# Extact everything in the Subject: header after the "[911] "
# and use formail to make that the new Subject:
:0 fhw
* ^Subject: *\[911\] \/.*
|formail -I"Subject: $MATCH"

I must be dense, here is the recipe I used to use, and now the one I tried
w/
your suggestion above.

previous recipe:
:0:
* ^TOrennlist
porsche

New recipe:
:0 fhw
* ^TOrennlist
* ^Subject: *\[911\] \/.*
|formail -I"Subject: $MATCH"
porsche

with the new recipe, I get the following in my logfile:

From campbell(_at_)Starbase(_dot_)NeoSoft(_dot_)COM  Wed Apr  7 13:00:34 1999
 Subject: 2.2.5 troubles: NFS client internals and PPP (digiboard pcxx)
  Folder: linux-kernel
3913
procmail: Skipped "* ^Subject: *\[911\] \/.*"
procmail: Skipped "|formail -I"Subject: $MATCH""
procmail: Skipped "* ^Subject: *\[911\] \/.*"
procmail: Skipped "|formail -I"Subject: $MATCH""


I'm not sure what I've done wrong, but I'm sure I've done something...

-chuck

--
ACCEL Services, Inc.| Specialists in Gravity, Magnetics |  1(713)993-0671
ph.
1980 Post Oak Blvd. |   and Integrated Interpretation   |  1(713)960-1157
fax
    Suite 2050      |                                   |
 Houston, TX, 77056 |          Chuck Campbell           |
campbell(_at_)neosoft(_dot_)com
                    |  President & Senior Geoscientist  |

     "Integration means more than having all the maps at the same scale!"



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