summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorjao <jao@gnu.org>2022-08-25 10:15:00 +0100
committerjao <jao@gnu.org>2022-08-25 10:15:00 +0100
commit87ea96e50e2552cd94638b973167e9afc911d371 (patch)
tree058b3e3fa747e71de1513ac5ca630e558d68cbfa
parent5cc664cbd71b48129b936b9314d6efb1f7b96930 (diff)
downloadelibs-87ea96e50e2552cd94638b973167e9afc911d371.tar.gz
elibs-87ea96e50e2552cd94638b973167e9afc911d371.tar.bz2
notmuch: better defaults for fcc-dirs
-rw-r--r--custom/jao-custom-notmuch.el3
-rw-r--r--lib/net/jao-notmuch.el9
2 files changed, 7 insertions, 5 deletions
diff --git a/custom/jao-custom-notmuch.el b/custom/jao-custom-notmuch.el
index f6ab68f..9ca937c 100644
--- a/custom/jao-custom-notmuch.el
+++ b/custom/jao-custom-notmuch.el
@@ -225,7 +225,8 @@
notmuch-draft-quoted-tags '("part")
notmuch-fcc-dirs
'(("\\(support\\|education\\)@bigml.com" . nil)
- (".*@bigml.com" . "bigml/trove -unread -new +sent +bigml +trove"))
+ (".*@bigml.com" . "bigml/trove -new -unread +sent +bigml +trove")
+ (".*" . "trove/jao -new -unread +sent +jao +trove"))
notmuch-maildir-use-notmuch-insert t)
:custom ((notmuch-address-internal-completion '(sent nil)))
diff --git a/lib/net/jao-notmuch.el b/lib/net/jao-notmuch.el
index 11b239f..5c0ba25 100644
--- a/lib/net/jao-notmuch.el
+++ b/lib/net/jao-notmuch.el
@@ -422,17 +422,18 @@
(jao-notmuch-tree--next nil nil t t)))
(defvar jao-notmuch-mua-reply-not-inherited
- '("attachment" "sent" "new" "unread" "bigml" "jao" "trove"))
+ '("attachment" "sent" "new" "bigml" "jao" "trove"))
(defun jao-notmuch-mua-new-reply (fun &rest args)
(let* ((otags (notmuch-show-get-tags))
(trove (or (seq-some (lambda (x) (and (member x otags) x))
- '("hacking" "bills" "feeds" "jao" "bigml"))
+ '("hacking" "bills" "feeds" "jao"))
"jao"))
(tags (seq-difference otags jao-notmuch-mua-reply-not-inherited))
(tagstr (mapconcat (lambda (s) (concat "+" s)) tags " "))
- (fcc (concat "trove/" trove " " tagstr " -new -unread +sent +trove"))
- (notmuch-fcc-dirs (append notmuch-fcc-dirs `((".*" . ,fcc)))))
+ (fcc (concat "trove/" trove " " tagstr " -new +sent +trove"))
+ (fcc-dirs (assoc-delete-all ".*" (copy-alist notmuch-fcc-dirs)))
+ (notmuch-fcc-dirs (append fcc-dirs `((".*" . ,fcc)))))
(apply fun args)))
(advice-add 'notmuch-mua-new-reply :around #'jao-notmuch-mua-new-reply)