summaryrefslogtreecommitdiff
path: root/notmuch-hook.sh
blob: c7e5478aa681279c86058cefd69a9232337f9ce1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
#!/usr/bin/env sh

# tag all messages from "me" as sent
notmuch tag +sent -inbox -unread -- from:ben@bsima.me

# tag TODOs from myself, always mark as unread so I'm forced to process them
notmuch tag +todo -inbox +unread -- subject:TODO and from:ben@bsima.me and to:ben@bsima.me

# tag some newsletters, but don't show them in inbox
notmuch tag +newsletters -inbox -- \
    from:the-morning-paper@onelanday.co.uk or \
    from:newsletter@fightaging.org or \
    subject:'The Reading List Email*' or \
    from:info@haskellweekly.news or \
    from:kale@hackernewsletter.com

# tag logwatch emails & remove from inbox
notmuch tag +logwatch -new -inbox -- subject:'Logwatch*'

# tag job-related emails
notmuch tag +jobs -inbox -- \
    from:alist.co or \
    from:angel.co or \
    from:stackoverflow.com or \
    from:stackoverflow.email or \
    from:cdmtechnology.com or \
    subject:job

# tag github emails
notmuch tag +github -inbox -- from:github.com

## mailing lists

notmuch tag -inbox +haskell -- to:haskell-cafe@haskell.org
notmuch tag -inbox +clojure -- to:clojure@googlegroups.com
notmuch tag -inbox +ai -- to:scikit-learn@python.org
notmuch tag -inbox +ai -- to:tensorflow.org