emacs: call notmuch-show instead of notmuch-search in buttonised id: links
authorJameson Graef Rollins <jrollins@finestructure.net>
Fri, 23 Dec 2011 04:59:12 +0000 (20:59 -0800)
committerDavid Bremner <bremner@debian.org>
Sat, 24 Dec 2011 19:32:01 +0000 (15:32 -0400)
Since message-ids necessarily match just a single message, there's no
reason to do a search for the id before viewing the actual message;
the search just becomes an extra screen to click through.  Clicking on
an id: links now just jumps straight to the message itself.

emacs/notmuch-show.el

index b565f336832382862101df17a7a203e76ce46561..eee4da9896434c327e545d904a058f4a0e2687d8 100644 (file)
@@ -803,7 +803,7 @@ a corresponding notmuch search."
       (remove-overlays (match-beginning 0) (match-end 0) 'goto-address t)
       (make-text-button (match-beginning 0) (match-end 0)
                        'action `(lambda (arg)
-                                  (notmuch-search ,(match-string-no-properties 0)))
+                                  (notmuch-show ,(match-string-no-properties 0)))
                        'follow-link t
                        'help-echo "Mouse-1, RET: search for this message"
                        'face goto-address-mail-face))))