Sieve: Avoiding duplicates in a folder while keeping in Inbox
Dear Folks,
I am in the process of learning Sieve, and want to be able to keep an email in Inbox, while also keeping *one* copy in another folder. However, the same mail is copied from Inbox multiple times when I run sieve-filter -Wev .dovecot.sieve Inbox
My attempt to prevent this fails: ... } elsif header :comparator "i;octet" :contains "From" "paypal@paypal.com.au" { if not duplicate { fileinto "paypal"; } keep; }
Please can anyone enlighten me?
On Tue, 2024-04-23 at 09:42 +1000, Nick Urbanik via dovecot wrote:
Dear Folks,
I am in the process of learning Sieve, and want to be able to keep an email in Inbox, while also keeping *one* copy in another folder. However, the same mail is copied from Inbox multiple times when I run sieve-filter -Wev .dovecot.sieve Inbox
My attempt to prevent this fails: ... } elsif header :comparator "i;octet" :contains "From" "paypal@paypal.com.au" { if not duplicate { fileinto "paypal"; } keep; }
Please can anyone enlighten me?
If there is a Dovecot Sieve mailing list, please point me to it.
dovecot mailing list -- dovecot@dovecot.org To unsubscribe send an email to dovecot-leave@dovecot.org
On Thu, 2024-04-25 at 14:36 +1000, Nick Urbanik via dovecot wrote:
On Tue, 2024-04-23 at 09:42 +1000, Nick Urbanik via dovecot wrote:
Dear Folks,
I am in the process of learning Sieve, and want to be able to keep an email in Inbox, while also keeping *one* copy in another folder. However, the same mail is copied from Inbox multiple times when I run sieve-filter -Wev .dovecot.sieve Inbox
My attempt to prevent this fails: ... } elsif header :comparator "i;octet" :contains "From" "paypal@paypal.com.au" { if not duplicate { fileinto "paypal"; } keep; }
Please can anyone enlighten me?
If there is a Dovecot Sieve mailing list, please point me to it.
OK, let me rephrase the problem:
I want to keep a copy of an email in Inbox and put a copy into another folder, but only once, even if I run sieve-filter as above multiple times. I know there are many who know how to do this and I would really appreciate your generous suggestions.
Op 13-5-2024 om 14:14 schreef Nick Urbanik via dovecot:
On Thu, 2024-04-25 at 14:36 +1000, Nick Urbanik via dovecot wrote:
On Tue, 2024-04-23 at 09:42 +1000, Nick Urbanik via dovecot wrote:
Dear Folks,
I am in the process of learning Sieve, and want to be able to keep an email in Inbox, while also keeping *one* copy in another folder. However, the same mail is copied from Inbox multiple times when I run sieve-filter -Wev .dovecot.sieve Inbox
My attempt to prevent this fails: ... } elsif header :comparator "i;octet" :contains "From" "paypal@paypal.com.au" { if not duplicate { fileinto "paypal"; } keep; }
Please can anyone enlighten me? If there is a Dovecot Sieve mailing list, please point me to it.
OK, let me rephrase the problem:
I want to keep a copy of an email in Inbox and put a copy into another folder, but only once, even if I run sieve-filter as above multiple times. I know there are many who know how to do this and I would really appreciate your generous suggestions.
The sieve-filter tool was mainly created to mend mailboxes after failures in sieve execution at delivery time. It currently does not provide access to the duplicate database and any actions that operate on it are ignored.
What exactly are you using sieve-filter for? Why are the Dovecot LDA or the Dovecot LMTP service with the Sieve plugin not fulfilling your needs?
Regards,
Stephan.
ok here are the basics
see example plugins below
plugin { mail_log_events = delete undelete expunge copy mailbox_delete mailbox_rename mail_log_fields = uid, box, msgid, from, subject, size, vsize, flags push_notification_driver = dlog
sieve = file:~/sieve/sieve;active=~/sieve/.dovecot.sieve sieve_duplicate_default_period = 1h sieve_duplicate_max_period = 1d
mail_replica = tcp:10.221.0.7:12345 #mail_replica = tcps:10.221.0.7 #mail_replica = remote:vmail@10.221.0.7 #replication_sync_timeout = 2
fts = lucene fts_lucene = whitespace_chars=@.
}
&
protocol sieve { managesieve_implementation_string = Dovecot Pigeonhole managesieve_max_line_length = 65536 }
basically
sieve_duplicate_default_period = 1h sieve_duplicate_max_period = 1d
handles the duplicate supression
see :
https://doc.dovecot.org/configuration_manual/sieve/extensions/duplicate/
Thanks - Paul Kudla (Manager SCOM.CA Internet Services Inc.)
Have A Happy Monday !!!
Scom.ca Internet Services http://www.scom.ca 004-1009 Byron Street South Whitby, Ontario - Canada L1N 4S3
Toronto 416.642.7266 Main 1.866.411.7266 Fax 1.888.892.7266 Email paul@scom.ca
On 5/13/2024 9:48 AM, Stephan Bosch via dovecot wrote:
Op 13-5-2024 om 14:14 schreef Nick Urbanik via dovecot:
On Thu, 2024-04-25 at 14:36 +1000, Nick Urbanik via dovecot wrote:
On Tue, 2024-04-23 at 09:42 +1000, Nick Urbanik via dovecot wrote:
Dear Folks,
I am in the process of learning Sieve, and want to be able to keep an email in Inbox, while also keeping *one* copy in another folder. However, the same mail is copied from Inbox multiple times when I run sieve-filter -Wev .dovecot.sieve Inbox
My attempt to prevent this fails: ... } elsif header :comparator "i;octet" :contains "From" "paypal@paypal.com.au" { if not duplicate { fileinto "paypal"; } keep; }
Please can anyone enlighten me? If there is a Dovecot Sieve mailing list, please point me to it.
OK, let me rephrase the problem:
I want to keep a copy of an email in Inbox and put a copy into another folder, but only once, even if I run sieve-filter as above multiple times. I know there are many who know how to do this and I would really appreciate your generous suggestions.
The sieve-filter tool was mainly created to mend mailboxes after failures in sieve execution at delivery time. It currently does not provide access to the duplicate database and any actions that operate on it are ignored.
What exactly are you using sieve-filter for? Why are the Dovecot LDA or the Dovecot LMTP service with the Sieve plugin not fulfilling your needs?
Regards,
Stephan.
dovecot mailing list -- dovecot@dovecot.org To unsubscribe send an email to dovecot-leave@dovecot.org
participants (3)
-
Nick Urbanik
-
Paul Kudla
-
Stephan Bosch