X-Git-Url: https://git.notmuchmail.org/git?p=notmuch;a=blobdiff_plain;f=emacs%2Fnotmuch-address.el;h=1a4cdda22b95ffee9434b589f0912700b8c22b02;hp=6e1364730d95edd519c2772b4ad6e83a9fac0440;hb=HEAD;hpb=055294454fb944a2aec062fbb974665b02d9eaeb diff --git a/emacs/notmuch-address.el b/emacs/notmuch-address.el index 6e136473..f756254c 100644 --- a/emacs/notmuch-address.el +++ b/emacs/notmuch-address.el @@ -153,8 +153,7 @@ matching `notmuch-address-completion-headers-regexp'." ;;; Setup (defun notmuch-address-selection-function (prompt collection initial-input) - "Call (`completing-read' - PROMPT COLLECTION nil nil INITIAL-INPUT 'notmuch-address-history)" + "Default address selection function: delegate to completing read." (completing-read prompt collection nil nil initial-input 'notmuch-address-history)) @@ -217,7 +216,7 @@ requiring external commands." ;; harvest if necessary. (notmuch-address-harvest-trigger))) (t - (process-lines notmuch-address-command original)))) + (notmuch--process-lines notmuch-address-command original)))) (defun notmuch-address-expand-name () (cond @@ -244,14 +243,8 @@ requiring external commands." (t (funcall notmuch-address-selection-function (format "Address (%s matches): " num-options) - ;; We put the first match as the initial - ;; input; we put all the matches as - ;; possible completions, moving the - ;; first match to the end of the list - ;; makes cursor up/down in the list work - ;; better. - (append (cdr options) (list (car options))) - (car options)))))) + options + orig))))) (if chosen (progn (push chosen notmuch-address-history) @@ -314,7 +307,7 @@ execution, CALLBACK is called when harvesting finishes." (and config-query (format " and (%s)" config-query))) from-or-to-me-query)) - (args `("address" "--format=sexp" "--format-version=4" + (args `("address" "--format=sexp" "--format-version=5" ,(if sent "--output=recipients" "--output=sender") "--deduplicate=address" ,query)))