mail filters

Benny Pedersen me at junc.eu
Tue Dec 13 01:55:21 UTC 2022


John Stoffel skrev den 2022-12-13 01:42:

> I use something like this and it's pretty good:
> 
>    require ["fileinto", "envelope"];
>    require "imap4flags";
>    require "regex";

can be merged into one line

>    if header :contains "Sender" "linux-kernel-owner at vger.kernel.org" {
>      fileinto "lkml";
>    }
>    elsif header :contains "X-Mailing-List" 
> "linux-kernel at vger.kernel.org"
>    {
>      fileinto "lkml";
>    }

can be merged into one line if "List-Id: Dovecot Mailing List 
<dovecot.dovecot.org>" is used

>    else {
>      # The rest goes into INBOX
>      # default is "implicit keep", we do it explicitly here
>      keep;
>    }
> 

posting to maillist will get dupes in return since message-id would not 
change, if any thing should be filtered as dupe delte the sent mail or 
do nothing :)


More information about the dovecot mailing list