Add key bindings 'z' to enter a notmuch-pick search and 'Z' to view the current `show' (i.e. a thread-id with some query) in notmuch-pick. --- emacs/notmuch-show.el | 8 ++++++++ 1 files changed, 8 insertions(+), 0 deletions(-) diff --git a/emacs/notmuch-show.el b/emacs/notmuch-show.el index 43408d9..244e18d 100644 --- a/emacs/notmuch-show.el +++ b/emacs/notmuch-show.el @@ -42,6 +42,7 @@ (declare-function notmuch-search-next-thread "notmuch" nil) (declare-function notmuch-search-show-thread "notmuch" nil) (declare-function notmuch-update-tags "notmuch" (current-tags tag-changes)) +(declare-function notmuch-pick "notmuch-pick" (query &optional query-context buffer-name)) (defcustom notmuch-message-headers '("Subject" "To" "Cc" "Date") "Headers that should be shown in a message, in this order. @@ -1158,6 +1159,8 @@ buffer is stored and re-applied after the refresh." (define-key map (kbd "<backtab>") 'notmuch-show-previous-button) (define-key map (kbd "TAB") 'notmuch-show-next-button) (define-key map "s" 'notmuch-search) + (define-key map "z" 'notmuch-pick) + (define-key map "Z" 'notmuch-show-pick-current-query) (define-key map "m" 'notmuch-mua-new-mail) (define-key map "f" 'notmuch-show-forward-message) (define-key map "r" 'notmuch-show-reply-sender) @@ -1565,6 +1568,11 @@ to show, nil otherwise." (notmuch-show-mark-read) (notmuch-show-message-adjust)) +(defun notmuch-show-pick-current-query () + "Call notmuch pick with the current query" + (interactive) + (notmuch-pick notmuch-show-thread-id notmuch-show-query-context)) + (defun notmuch-show-view-raw-message () "View the file holding the current message." (interactive) -- 1.7.2.3