mail and packages

This commit is contained in:
Ingolf Wagner 2021-10-31 13:16:44 +01:00
parent 9d702aac41
commit 11d07f2dd8
No known key found for this signature in database
GPG key ID: 76BF5F1928B9618B
3 changed files with 22 additions and 15 deletions

View file

@ -23,7 +23,7 @@ in {
exec ${pkgs.nixUnstable}/bin/nix --experimental-features "nix-command flakes" "$@" exec ${pkgs.nixUnstable}/bin/nix --experimental-features "nix-command flakes" "$@"
'') '')
#sweethome3d.application sweethome3d.application
pkgs.polygon-art.polygon-art pkgs.polygon-art.polygon-art
# bluetooth gui # bluetooth gui
@ -34,24 +34,24 @@ in {
inkscape inkscape
imagemagick imagemagick
#bitwig-studio3 bitwig-studio3
#sononym-crawler sononym-crawler
#darktable darktable
# rust development environment # rust development environment
#rustup rustup
#jetbrains.clion jetbrains.clion
# general # general
#jetbrains.idea-ultimate jetbrains.idea-ultimate
#vscode #vscode
# python # python
#python3Full python3Full
#jetbrains.pycharm-professional jetbrains.pycharm-professional
#jetbrains.datagrip jetbrains.datagrip
#element-desktop element-desktop
#tor-browser-bundle-bin #tor-browser-bundle-bin
#(tor-browser-bundle-bin.overrideAttrs (old: rec { #(tor-browser-bundle-bin.overrideAttrs (old: rec {

View file

@ -672,7 +672,13 @@ in {
}; };
# fetch mails every 10 minutes # fetch mails every 10 minutes
systemd.services.fetchmail = { systemd.services.fetchmail =
let
threadTag = tag: ''
echo "tag threads with ${tag}"
${pkgs.notmuch}/bin/notmuch tag +${tag} $(${pkgs.notmuch}/bin/notmuch search --output=threads tag:${tag})
'';
in {
enable = true; enable = true;
serviceConfig = { User = config.users.users.mailUser.name; }; serviceConfig = { User = config.users.users.mailUser.name; };
environment.NOTMUCH_CONFIG = environment.NOTMUCH_CONFIG =
@ -690,8 +696,9 @@ in {
echo "run notmuch" echo "run notmuch"
${pkgs.notmuch}/bin/notmuch new ${pkgs.notmuch}/bin/notmuch new
${notmuchTaggingNew} ${notmuchTaggingNew}
echo "mute threads" ${threadTag "muted"}
${pkgs.notmuch}/bin/notmuch tag +muted $(${pkgs.notmuch}/bin/notmuch search --output=threads tag:muted) ${threadTag "wohnung"}
${threadTag "flagged"}
echo "delete threads" echo "delete threads"
${pkgs.notmuch}/bin/notmuch tag +deleted $(${pkgs.notmuch}/bin/notmuch search --output=threads tag:deleted) ${pkgs.notmuch}/bin/notmuch tag +deleted $(${pkgs.notmuch}/bin/notmuch search --output=threads tag:deleted)
''; '';

View file

@ -189,7 +189,7 @@ in {
set index_format="${index_format} %r |" set index_format="${index_format} %r |"
folder-hook 'Discourse.*' 'set sort=reverse-date' folder-hook 'Discourse.*' 'set sort=reverse-date'
virtual-mailboxes "INBOX" "notmuch://?query=(tag:inbox or (tag:sent and not tag:archive)) AND NOT tag:discourse AND NOT tag:muted AND NOT tag:list AND NOT tag:fraud AND NOT tag:junk" virtual-mailboxes "INBOX" "notmuch://?query=(tag:inbox or (tag:sent and not tag:archive)) AND NOT tag:muted AND NOT tag:list AND NOT tag:fraud AND NOT tag:junk"
virtual-mailboxes "Unread" "notmuch://?query=(tag:unread AND NOT tag:muted)" virtual-mailboxes "Unread" "notmuch://?query=(tag:unread AND NOT tag:muted)"
virtual-mailboxes "Space left" "notmuch://?query=((tag:spaceleft OR tag:space-lef) AND NOT tag:muted)" virtual-mailboxes "Space left" "notmuch://?query=((tag:spaceleft OR tag:space-lef) AND NOT tag:muted)"
virtual-mailboxes "Sononym" "notmuch://?query=(tag:sononym AND NOT tag:muted)" virtual-mailboxes "Sononym" "notmuch://?query=(tag:sononym AND NOT tag:muted)"