[PATCH] emacs: Tab completion for notmuch-search and notmuch-search-filter

Jameson Graef Rollins jrollins at finestructure.net
Fri Aug 5 14:00:20 PDT 2011


On Fri, 05 Aug 2011 17:17:56 +0200, Daniel Schoepe <daniel.schoepe at googlemail.com> wrote:
> On Mon, 06 Jun 2011 18:32:41 +0200, Daniel Schoepe <daniel.schoepe at googlemail.com> wrote:
> I've been using this patch for the past two months now and it has been
> working fine. Are there any more suggestions or criticisms about this?

Hey, Daniel.  This is a really great patch.  I've been looking for this
functionality for a while.  Thanks for implementing it.

Following this email I am sending a slightly-tweaked and signed-off
version of this patch that includes a couple of minor tweaks (diff
below).  The first tweak removes an errant white space, and the other
modifies the tag-retrieval command to use the "search --output=tags"
command instead of the "search-tags" command which was recently
deprecated.

jamie.

diff --git a/emacs/notmuch.el b/emacs/notmuch.el
index e9b0ef8..053f0be 100644
--- a/emacs/notmuch.el
+++ b/emacs/notmuch.el
@@ -882,12 +882,12 @@ characters as well as `_.+-'.
 
 PROMPT is the string to prompt with."
   (lexical-let
-      ((completions 
+      ((completions
        (append (list "folder:" "thread:" "id:" "date:" "from:" "to:"
                      "subject:" "attachment:")
                (mapcar (lambda (tag)
                          (concat "tag:" tag))
-                       (process-lines "notmuch" "search-tags")))))
+                       (process-lines "notmuch" "search" "--output=tags" "*")))))
     (let ((keymap (copy-keymap minibuffer-local-map))
          (minibuffer-completion-table
           (completion-table-dynamic
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 835 bytes
Desc: not available
URL: <http://notmuchmail.org/pipermail/notmuch/attachments/20110805/1fae0a53/attachment.pgp>


More information about the notmuch mailing list