FolderNameFilter: allow multiple tags per folder#343
FolderNameFilter: allow multiple tags per folder#343mjg wants to merge 1 commit intoafewmail:masterfrom
Conversation
|
FTR: CI runs stone age notmuch (0.29) against py 3.12 which is doomed to fail. The fix for ConfigParser in py 3.12 is in the latest notmuch 0.38 only. |
8edec78 to
f67f100
Compare
|
Hey @mjg I feel this use case is a bit unclear to me, can you detail a bit how this could append ? |
Sure, I didn't meet my own standard on commit messages, sorry :-) Here's the why: Say, I have accounts Work and Pleasure whose mail ends up in subdirs of directories and of course more for other folders. I know the account tag search is equivalent to a path search, but the tag is nice with clients which display it; besides, I can remove/replace the tag and have the |
So far, the last entry wins when a folder is specified multiple times as a folder transform. The reason is that the folder name is a key in a dict whose values are tags. On the other hand, if a message has copies in several folders then all these rules apply. Change (fix?) afew's FolderNameFilter so that multiple transforms for the same folder lead to multiple tags being added. Technically, this is done by using sets as values in the transform dict. In the future, we might think about implementing notmuch-tag style notation (with the obvious quoting issues).
f67f100 to
b9f69f7
Compare
|
Hey @mjg,
|
Yes, I should amend
We don't have any test for Besides, I would rebase this PR on top of the notmuch2 PR once it is merged. (Merging both works, too.) |
So far, the last entry wins when a folder is specified multiple times as a folder transform. The reason is that the folder name is a key in a dict whose values are tags. On the other hand, if a message has copies in several folders then all these rules apply.
Change (fix?) afew's FolderNameFilter so that multiple transforms for the same folder lead to multiple tags being added. Technically, this is done by using sets as values in the transform dict.
In the future, we might think about implementing notmuch-tag style notation (with the obvious quoting issues).