From: William Casarin <jb55@jb55.com>
To: notmuch@notmuchmail.org
Cc: Teemu Likonen <tlikonen@iki.fi>, William Casarin <jb55@jb55.com>
Subject: [PATCH v2 3/3] emacs/tree: add notmuch-tree-archive-thread-then-next
Date: Tue, 11 Aug 2020 10:36:53 -0700 [thread overview]
Message-ID: <20200811173653.18109-3-jb55@jb55.com> (raw)
In-Reply-To: <20200811173653.18109-1-jb55@jb55.com>
Now that notmuch-tree-next-thread acts more like its notmuch-show
counterpart, let's update the binding to move to the next thread after
archiving.
Signed-off-by: William Casarin <jb55@jb55.com>
---
emacs/notmuch-tree.el | 8 +++++++-
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/emacs/notmuch-tree.el b/emacs/notmuch-tree.el
index bf500b60..2bb7c80f 100644
--- a/emacs/notmuch-tree.el
+++ b/emacs/notmuch-tree.el
@@ -338,7 +338,7 @@ FUNC."
(define-key map [mouse-1] 'notmuch-tree-show-message)
(define-key map "x" 'notmuch-tree-archive-message-then-next-or-exit)
(define-key map "X" 'notmuch-tree-archive-thread-then-exit)
- (define-key map "A" 'notmuch-tree-archive-thread)
+ (define-key map "A" 'notmuch-tree-archive-thread-then-next)
(define-key map "a" 'notmuch-tree-archive-message-then-next)
(define-key map "z" 'notmuch-tree-to-tree)
(define-key map "n" 'notmuch-tree-next-matching-message)
@@ -497,6 +497,12 @@ NOT change the database."
(notmuch-tree-close-message-window)
(notmuch-tree query)))
+(defun notmuch-tree-archive-thread-then-next ()
+ "Archive all messages in the current buffer, then show next thread from search."
+ (interactive)
+ (notmuch-tree-archive-thread)
+ (notmuch-tree-next-thread))
+
(defun notmuch-unthreaded-from-tree-current-query ()
"Switch from tree view to unthreaded view."
(interactive)
--
2.28.0
next prev parent reply other threads:[~2020-08-11 17:43 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-08-11 17:36 [PATCH v2 1/3] emacs/tree: introduce notmuch-tree-parent-buffer variable William Casarin
2020-08-11 17:36 ` [PATCH v2 2/3] emacs/tree: enable moving to next thread in search results William Casarin
2020-08-15 12:54 ` David Bremner
2020-08-11 17:36 ` William Casarin [this message]
2020-08-15 12:32 ` [PATCH v2 1/3] emacs/tree: introduce notmuch-tree-parent-buffer variable David Bremner
2020-08-15 12:41 ` David Bremner
2020-08-16 13:59 ` David Bremner
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://notmuchmail.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200811173653.18109-3-jb55@jb55.com \
--to=jb55@jb55.com \
--cc=notmuch@notmuchmail.org \
--cc=tlikonen@iki.fi \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://yhetil.org/notmuch.git/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).