summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorjao <jao@gnu.org>2022-02-25 19:42:30 +0000
committerjao <jao@gnu.org>2022-02-25 22:04:19 +0000
commit30eb7a1b7fc286c57cecfedf4d19b98e8b658347 (patch)
tree98d1540712c285dd9d0b7d791aaf574557860265
parenta2b76afc2b92b7706fcd5dfe4e379768c7eebd98 (diff)
downloadelibs-30eb7a1b7fc286c57cecfedf4d19b98e8b658347.tar.gz
elibs-30eb7a1b7fc286c57cecfedf4d19b98e8b658347.tar.bz2
notmuch fixlets
-rw-r--r--lib/net/jao-notmuch.el11
-rw-r--r--notmuch.org26
2 files changed, 14 insertions, 23 deletions
diff --git a/lib/net/jao-notmuch.el b/lib/net/jao-notmuch.el
index fe3e086..f057a55 100644
--- a/lib/net/jao-notmuch.el
+++ b/lib/net/jao-notmuch.el
@@ -238,11 +238,12 @@
(nc (append n (or (jao-notmuch--message-counts t) '(0 0 0))))
(q (buffer-name)))
(with-current-buffer mb
- (let ((s (thread-last (notmuch-show-get-subject)
- (notmuch-show-strip-re)
- (notmuch-sanitize))))
- (setq-local header-line-format
- (apply 'jao-notmuch--format-counts s q nc))))))
+ (when (derived-mode-p 'notmuch-show-mode)
+ (let ((s (thread-last (notmuch-show-get-subject)
+ (notmuch-show-strip-re)
+ (notmuch-sanitize))))
+ (setq-local header-line-format
+ (apply 'jao-notmuch--format-counts s q nc)))))))
(defun jao-notmuch-tree--find-update-header-line (&rest _args)
(when-let ((mb (if (derived-mode-p 'notmuch-show-mode)
diff --git a/notmuch.org b/notmuch.org
index 125db3d..6dc0a35 100644
--- a/notmuch.org
+++ b/notmuch.org
@@ -93,25 +93,22 @@
"gr-qc"
"quant-ph"))
`(,(jao-notmuch--qn "feeds" "prog" "fp"
- '("tag:prog" "not tag:\"/emacs/\"")))))
+ '("tag:prog" "not tag:\"/emacs/\"")))))
- (defvar jao-notmuch-bigml-searches
+ (defvar jao-notmuch-inbox-searches
`(,(jao-notmuch--q "bigml" "inbox" "bi")
,(jao-notmuch--q "bigml" "support" "bs")
,(jao-notmuch--q "bigml" "bugs" "bb")
,(jao-notmuch--q "bigml" "drivel" "bd")
- ,(jao-notmuch--q "bigml" "lists" "bl")))
-
- (defvar jao-notmuch-jao-searches
- `(,(jao-notmuch--q "jao" "inbox" "ji")
+ ,(jao-notmuch--q "bigml" "lists" "bl")
+ ,(jao-notmuch--q "jao" "inbox" "ji")
,(jao-notmuch--q "jao" "bills" "jb")
,(jao-notmuch--q "jao" "drivel" "jd")
,(jao-notmuch--q "jao" "mdk" "jm")
+ ,(jao-notmuch--qn "jao" "hacking" "jh"
+ '("tag:hacking" "not tag:\"/emacs/\""))
,(jao-notmuch--q "jao" "local" "l")))
- (defvar jao-notmuch-inbox-searches
- (append jao-notmuch-bigml-searches jao-notmuch-jao-searches))
-
(defvar jao-notmuch-emacs-searches
`(,(jao-notmuch--sq "emacs" "ee" "emacs" "feeds")
,(jao-notmuch--sq "emacs-github" "eg" "emacs" "github")
@@ -121,8 +118,7 @@
,(jao-notmuch--sq "emacs-orgmode" "eo" "emacs" "org")))
(setq notmuch-saved-searches
- (append jao-notmuch-bigml-searches
- jao-notmuch-jao-searches
+ (append jao-notmuch-inbox-searches
jao-notmuch-feed-searches
jao-notmuch-emacs-searches))
@@ -202,7 +198,7 @@
(setq notmuch-address-use-company nil
notmuch-address-command (if jao-notmuch-enabled 'internal 'as-is)
notmuch-always-prompt-for-sender t
- notmuch-draft-folder "drafts"
+ notmuch-draft-folder "local"
notmuch-draft-quoted-tags '("part")
notmuch-address-internal-completion '(received nil)
notmuch-fcc-dirs
@@ -242,12 +238,6 @@
(notmuch-hello-insert-buttons searches))
(indent-rigidly start (point) notmuch-hello-indent))))
- (defun jao-notmuch-hello-insert-bigml-searches ()
- (jao-notmuch-hello--insert-searches jao-notmuch-bigml-searches "work"))
-
- (defun jao-notmuch-hello-insert-jao-searches ()
- (jao-notmuch-hello--insert-searches jao-notmuch-jao-searches "jao"))
-
(defun jao-notmuch-hello-insert-inbox-searches ()
(jao-notmuch-hello--insert-searches jao-notmuch-inbox-searches "inbox"))