aboutsummaryrefslogtreecommitdiffstats
path: root/worker/middleware
Commit message (Collapse)AuthorAgeFilesLines
* foldermap: make folder-map syntax more expressiveKoni Marti2023-07-142-11/+137
| | | | | | | | | | | | | | | | | | | | | | | | | Improve the folder mapping syntax so that prefixes can be removed completely. The following line in the folder-map file * = INBOX/* will strip the INBOX/ prefix from all subfolders of INBOX, e.g. map "INBOX/Project1" to "Project1". To prevent a key collision with multiple "*" keys (the folder mapping is stored as a map internally), a group of "*" will be condensed to one "*", e.g. ** = INBOX/* has the same meaning as above. Also, adjust name translation for folder creation and add tests. Fixes: https://todo.sr.ht/~rjarry/aerc/176 Signed-off-by: Koni Marti <koni.marti@gmail.com> Acked-by: Robin Jarry <robin@jarry.cc> Tested-by: Bence Ferdinandy <bence@ferdinandy.com>
* worker: implement folder-map middlewareKoni Marti2023-06-221-0/+152
Implement a folder-map middleware that will translate the folder names between the ui and the backend according to a provided key-value map. Fixes: https://todo.sr.ht/~rjarry/aerc/175 Signed-off-by: Koni Marti <koni.marti@gmail.com> Tested-by: Bence Ferdinandy <bence@ferdinandy.com> Signed-off-by: Robin Jarry <robin@jarry.cc>