[WIP2 11/12] emacs: convert notmuch-tree to format-version 3

David Bremner david at tethera.net
Sun Apr 5 15:59:13 PDT 2015


This is similarly trivial conversion to that applied to
notmuch-search, and is subject to the same objections
---
 emacs/notmuch-tree.el | 11 ++++++-----
 1 file changed, 6 insertions(+), 5 deletions(-)

diff --git a/emacs/notmuch-tree.el b/emacs/notmuch-tree.el
index ca5f9b6..bae3de0 100644
--- a/emacs/notmuch-tree.el
+++ b/emacs/notmuch-tree.el
@@ -774,10 +774,11 @@ message together with all its descendents."
 
 (defun notmuch-tree-insert-forest-thread (forest-thread)
   "Insert a single complete thread."
-  (let (tree-status)
-    ;; Reset at the start of each main thread.
-    (setq notmuch-tree-previous-subject nil)
-    (notmuch-tree-insert-thread forest-thread 0 tree-status)))
+  (unless (notmuch-query-metadata-p forest-thread)
+    (let (tree-status)
+      ;; Reset at the start of each main thread.
+      (setq notmuch-tree-previous-subject nil)
+      (notmuch-tree-insert-thread forest-thread 0 tree-status))))
 
 (defun notmuch-tree-insert-forest (forest)
   "Insert a forest of threads.
@@ -871,7 +872,7 @@ the same as for the function notmuch-tree."
     (notmuch-tag-clear-cache)
     (let ((proc (notmuch-start-notmuch
 		 "notmuch-tree" (current-buffer) #'notmuch-tree-process-sentinel
-		 "show" "--body=false" "--format=sexp" "--format-version=2"
+		 "show" "--body=false" "--format=sexp" "--format-version=3"
 		 message-arg search-args))
 	  ;; Use a scratch buffer to accumulate partial output.
 	  ;; This buffer will be killed by the sentinel, which
-- 
2.1.4



More information about the notmuch mailing list