summaryrefslogtreecommitdiff
path: root/.fmail
diff options
context:
space:
mode:
authorSean Whitton <spwhitton@spwhitton.name>2022-02-22 09:57:27 -0700
committerSean Whitton <spwhitton@spwhitton.name>2022-02-22 15:41:11 -0700
commit4df9fd28776e563f7876e213cc1756c43c216b22 (patch)
tree568ec41a7e23e1f6fff8f0807562fd7105bfca42 /.fmail
parent176cd2fa0485bcefe62f932d1b5c281db2318a20 (diff)
downloaddotfiles-4df9fd28776e563f7876e213cc1756c43c216b22.tar.gz
add killfile-based notmuch tagging
Diffstat (limited to '.fmail')
-rwxr-xr-x.fmail/.notmuch/hooks/post-new5
1 files changed, 5 insertions, 0 deletions
diff --git a/.fmail/.notmuch/hooks/post-new b/.fmail/.notmuch/hooks/post-new
index 89437063..5559de87 100755
--- a/.fmail/.notmuch/hooks/post-new
+++ b/.fmail/.notmuch/hooks/post-new
@@ -20,3 +20,8 @@ notmuch tag +deleted -- folder:trash
# mark messages as read in threads I've killed. don't propagate the
# spw::killed tag itself
notmuch tag -unread -- 'thread:{tag:spw::killed}'
+
+[ -r "$HOME/doc/conf/killfile" ] && perl \
+ -we'length and system "notmuch", "tag", "-unread", "--", "($_)"
+ for join ") or (", grep length, map s/^\s+|\s*(#.*)?$//gr, <>' \
+ "$HOME/doc/conf/killfile"