X-Git-Url: https://git.notmuchmail.org/git?p=notmuch;a=blobdiff_plain;f=emacs%2Fnotmuch-show.el;h=7d9f8a905f9103e378249069948c33709daca4dd;hp=20f89970a00a7008fadf818e5873662c12c48c06;hb=11a220a3c1b4c78d6fa994766a5e192d5619751e;hpb=776e21d953326f1d7c3317215d11c53ad6eaaf08 diff --git a/emacs/notmuch-show.el b/emacs/notmuch-show.el index 20f89970..7d9f8a90 100644 --- a/emacs/notmuch-show.el +++ b/emacs/notmuch-show.el @@ -1905,10 +1905,16 @@ thread from search." (interactive) (notmuch-common-do-stash (notmuch-show-get-from))) -(defun notmuch-show-stash-message-id () - "Copy id: query matching the current message to kill-ring." - (interactive) - (notmuch-common-do-stash (notmuch-show-get-message-id))) +(defun notmuch-show-stash-message-id (&optional stash-thread-id) + "Copy id: query matching the current message to kill-ring. + +If invoked with a prefix argument (or STASH-THREAD-ID is +non-nil), copy thread: query matching the current thread to +kill-ring." + (interactive "P") + (if stash-thread-id + (notmuch-common-do-stash notmuch-show-thread-id) + (notmuch-common-do-stash (notmuch-show-get-message-id)))) (defun notmuch-show-stash-message-id-stripped () "Copy message ID of current message (sans `id:' prefix) to kill-ring."