X-Git-Url: https://git.notmuchmail.org/git?a=blobdiff_plain;f=emacs%2Fnotmuch.el;h=3acd3a973a8a68d55d73214a2581c473797422e6;hb=cdd64727f197bf9e24b89da768d75bf268b8fb1c;hp=be09f424a953c0686f552b7dd012ef5747b3d01a;hpb=7d06e14e79f41c485f6cb448994498c5581dc69d;p=notmuch diff --git a/emacs/notmuch.el b/emacs/notmuch.el index be09f424..3acd3a97 100644 --- a/emacs/notmuch.el +++ b/emacs/notmuch.el @@ -234,7 +234,7 @@ For a mouse binding, return nil." "Notmuch mail reader for Emacs." :group 'mail) -(defcustom notmuch-search-hook nil +(defcustom notmuch-search-hook '(hl-line-mode) "List of functions to call when notmuch displays the search results." :type 'hook :options '(hl-line-mode) @@ -268,7 +268,6 @@ For a mouse binding, return nil." (define-key map "-" 'notmuch-search-remove-tag) (define-key map "+" 'notmuch-search-add-tag) (define-key map (kbd "RET") 'notmuch-search-show-thread) - (define-key map "F" 'notmuch-folder) map) "Keymap for \"notmuch search\" buffers.") (fset 'notmuch-search-mode-map notmuch-search-mode-map) @@ -773,8 +772,12 @@ search." Runs a new search matching only messages that match both the current search results AND the additional query string provided." (interactive "sFilter search: ") - (let ((grouped-query (if (string-match-p notmuch-search-disjunctive-regexp query) (concat "( " query " )") query))) - (notmuch-search (concat notmuch-search-query-string " and " grouped-query) notmuch-search-oldest-first))) + (let ((grouped-query (if (string-match-p notmuch-search-disjunctive-regexp query) + (concat "( " query " )") + query))) + (notmuch-search (if (string= notmuch-search-query-string "*") + grouped-query + (concat notmuch-search-query-string " and " grouped-query)) notmuch-search-oldest-first))) (defun notmuch-search-filter-by-tag (tag) "Filter the current search results based on a single tag.