From 85c68fc6763b73525c9e03ac2efae25c80793a82 Mon Sep 17 00:00:00 2001 From: Marty Oehme Date: Mon, 21 Sep 2020 09:38:40 +0200 Subject: [PATCH] mail: Add local folder and tag alignment afew will locally add notmuch tags to mails, as well as move them to specific folders according to the notmuch tags they already contain. This sets mails residing in the `Dump` folder to be tagged correspondingly with `dump`. (imapfilter automatically puts all filtered adverts and mailing lists into the dump folder beforehand.) On the other hand, it makes sure that email tagged with `dump` also resides in the `Dump` folder (if tagged manually with notmuch), and same thing for `Inbox`. --- mail/.config/afew/config | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/mail/.config/afew/config b/mail/.config/afew/config index 3aabf78..6333e2d 100644 --- a/mail/.config/afew/config +++ b/mail/.config/afew/config @@ -1,6 +1,19 @@ [SpamFilter] [KillThreadsFilter] [ListMailsFilter] +[FolderNameFilter] +folder_explicit_list = Dump +folder_transforms = Dump:dump +maildir_separator = / [ArchiveSentMailsFilter] sent_tag=sent [InboxFilter] + +[MailMover] +folders = Inbox Dump +rename = True +max_age = 15 + +# rules +Inbox = 'tag:dump':Dump +Dump = 'NOT tag:spam AND NOT tag:dump AND tag:inbox':Inbox