imapnotify only send notification on new mail

This commit is contained in:
Evie Litherland-Smith 2023-09-29 12:37:58 +01:00
parent bde020a7b2
commit 187b8f271e

View file

@ -40,8 +40,10 @@
enable = true;
boxes = [ "INBOX" ];
onNotify = "${pkgs.isync}/bin/mbsync --pull proton:INBOX";
onNotifyPost =
"${pkgs.libnotify}/bin/notify-send 'Proton: New mail arrived'";
onNotifyPost = {
mail =
"${pkgs.libnotify}/bin/notify-send 'Proton: New mail arrived'";
};
extraConfig = {
tls = false;
tlsOptions.rejectUnauthorized = false;
@ -78,8 +80,10 @@
enable = true;
boxes = [ "INBOX" ];
onNotify = "${pkgs.isync}/bin/mbsync --pull icloud:INBOX";
onNotifyPost =
"${pkgs.libnotify}/bin/notify-send 'iCloud: New mail arrived'";
onNotifyPost = {
mail =
"${pkgs.libnotify}/bin/notify-send 'Proton: New mail arrived'";
};
};
mbsync = {
enable = true;
@ -115,8 +119,10 @@
enable = true;
boxes = [ "INBOX" ];
onNotify = "${pkgs.isync}/bin/mbsync --pull ukaea:INBOX";
onNotifyPost =
"${pkgs.libnotify}/bin/notify-send 'UKAEA: New mail arrived'";
onNotifyPost = {
mail =
"${pkgs.libnotify}/bin/notify-send 'Proton: New mail arrived'";
};
extraConfig = {
tls = false;
tlsOptions.rejectUnauthorized = false;