diff --git a/home/common/files/notmuch/post-new b/home/common/files/notmuch/post-new index d6a40da..ea5ccb5 100755 --- a/home/common/files/notmuch/post-new +++ b/home/common/files/notmuch/post-new @@ -1,5 +1,7 @@ #!/usr/bin/env bash +afew --tag --all >> /dev/null 2>&1 +exit addtag() { tags="${1}" field="${2}" diff --git a/home/common/mail.nix b/home/common/mail.nix index ff28d10..d3ed2ab 100644 --- a/home/common/mail.nix +++ b/home/common/mail.nix @@ -24,33 +24,53 @@ }; }; - programs.notmuch = { - enable = true; - new = { - tags = ["new" "unread"]; - ignore = [ - ".mbsyncstate" - ".uidvalidity" - ".mbsyncstate.journal" - ".mbsyncstate.new" - ".mbsyncstate.lock" - ]; + programs = { + afew = { + enable = true; + extraConfig = + '' + [FolderNameFilter] + # folder_explicit_list = aurora development kisd mailing-lists news pen Sent-Mail uh + # folder_blacklist = Inbox All-Mail Drafts Trash + folder_blacklist = All-Mail Trash + [SpamFilter] + [KillThreadsFilter] + [ListMailsFilter] + [ArchiveSentMailsFilter] + [InboxFilter] + ''; }; - maildir = { - synchronizeFlags = true; - }; - extraConfig = { - index = { - "header.List" = "List-Id"; + notmuch = { + enable = true; + new = { + tags = ["new" "unread"]; + ignore = [ + ".mbsyncstate" + ".uidvalidity" + ".mbsyncstate.journal" + ".mbsyncstate.new" + ".mbsyncstate.lock" + ]; }; - database = { - path = "/home/don/Mail"; - hook_dir = "/home/don/.config/notmuch/hooks"; + maildir = { + synchronizeFlags = true; + }; + extraConfig = { + index = { + "header.List" = "List-Id"; + }; + database = { + path = "/home/don/Mail"; + hook_dir = "/home/don/.config/notmuch/hooks"; + }; }; }; }; xdg.configFile."notmuch/hooks/post-new".source = ./files/notmuch/post-new; + # xdg.configFile."notmuch/hooks/post-new".text = '' + # ${pkgs.afew}/bin/afew --tag --all + # ''; xdg.configFile."neomutt/neomuttrc".source = ./files/neomutt/neomuttrc; xdg.configFile."neomutt/mailcap".source = ./files/neomutt/mailcap;