procmail
[Top] [All Lists]

Multiple recipients - too many emails

2009-09-17 09:27:26
I use fetchmail to download all the various email from different
accounts my wife and I have. The plan is to use fetchmail to add a
custom header to the email depending on to whom it's addressed. Once
all the address checking and header adding has been done the email is
to go off to dovecot sieve which will check the headers and deliver
the mail to the right Maildir folders under a single account - this
way all our email is in one accessible place and is segregated into
appropriate folders, and we like it this way. This is all good...up to
a point...

If an email is addressed to both of us I've worked out how to add a
header for both of us. But there are actually 2 emails and each has 2
headers (one for me and one for wife) so dovecot delivers 2 copies of
the email to my Maildir folder AND 2 to my wife's. Can anyone think of
a way of only delivering 1 to each of our folders?

My .dovecot.sieve file looks like this:

    require ["fileinto"];

    if header :contains "X-PMERule" "wife email address" {
       fileinto "Wife";
    }

    if header :contains "X-PMERule" "husband email address" {
       fileinto "Husband";
    }

Regards,
Phill
____________________________________________________________
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

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