Simon Bruder
2787c28a3d
Aerc’s notmuch support is not yet very mature, so it needs a hacky workaround to work somewhat well.
22 lines
646 B
Nix
22 lines
646 B
Nix
{
|
|
programs.mbsync.enable = true;
|
|
# TODO: remove when copy-to is implemented in aerc for notmuch
|
|
programs.msmtp.enable = true;
|
|
programs.notmuch = {
|
|
enable = true;
|
|
hooks = {
|
|
preNew = ''
|
|
mbsync --all
|
|
'';
|
|
postNew = ''
|
|
notmuch tag +sent -inbox -unread "folder:personal/Sent"
|
|
|
|
notmuch tag +ebay "to:ebay@sbruder.de"
|
|
notmuch tag +kleinanzeigen "to:ebay-kleinanzeigen@sbruder.de"
|
|
notmuch tag +git "from:{.*@github.com or .*@gitlab.com or (no-reply+)?gitea@sbruder.de} or subject:[PATCH]"
|
|
notmuch tag +newsletter "subject:newsletter and tag:unread"
|
|
'';
|
|
};
|
|
};
|
|
}
|