Don't notify on 0 emails

This commit is contained in:
Charlotte Van Petegem 2021-01-06 16:13:30 +01:00
parent dbe32eef7f
commit 56f5701af7
No known key found for this signature in database
GPG key ID: 019E764B7184435A

View file

@ -7,7 +7,8 @@ let
if [ "$unseen_count" = "1" ]
then
${pkgs.libnotify}/bin/notify-send -t 5000 'New ${name} mail arrived' "1 unseen mail"
else
elif [ "$unseen_count" != "0" ]
then
${pkgs.libnotify}/bin/notify-send -t 5000 'New ${name} mail arrived' "$unseen_count unseen mails"
fi
'';