procmail
[Top] [All Lists]

Re: filtering to two folders

1995-11-13 03:53:52
Soren tries to help me:
:0 H
* ^From.*jimo
* ^Subject: test
{
    :0 cf

      Here you are telling it to deliver to your pipe and then to continue

And Steven adds:
Which is an impossible combination, because filtering the mail through
a program cannot cause the mail to be cloned.

Ok, I understand that the c flag copies only around the recipe it's on.
I then tried:
{
    :0 f
    | formail -k -X From -X From: -X Subject: -X Date: 
        :0 ca: 
        test1

    :0 f
    | formail -k -X From -X From: -X Subject: -X Date: -X Message-Id:
        :0 a:
        test2
}
and
{
    :0 cf
    | formail -k -X From -X From: -X Subject: -X Date: 
        :0 ca: 
        test1

    :0 f
    | formail -k -X From -X From: -X Subject: -X Date: -X Message-Id:
        :0 a:
        test2
}
both of which result in test2 getting a header stripped of its Message-Id:

Next I tried this, thinking the copying would take place before the 
first pipe:
{
    :0 cfw:
    | formail -k -X From -X From: -X Subject: -X Date: >>test1

    :0 f
    | formail -k -X From -X From: -X Subject: -X Date: -X Message-Id:
        :0 a:
        test2
}

which results in test2 getting an empty message from foo(_at_)bar,

I'm hoping Steven's remark doesn't mean it's impossible to pass mail
through two different filters (surely not :).  I'm afraid I still
don't see how to make a complete copy so the second filter has the
whole thing to work on.  Where does the carbon-copying take place?
Sorry to be so thick.

jimo(_at_)eskimo(_dot_)com

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