emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] scratch/gnus-search 2ae2549 24/30: Fix bum namazu search c


From: Eric Abrahamsen
Subject: [Emacs-diffs] scratch/gnus-search 2ae2549 24/30: Fix bum namazu search command
Date: Thu, 1 Jun 2017 03:50:23 -0400 (EDT)

branch: scratch/gnus-search
commit 2ae25496a1f7e44050f495eae3dca8b07f64ea15
Author: Eric Abrahamsen <address@hidden>
Commit: Eric Abrahamsen <address@hidden>

    Fix bum namazu search command
    
    * lisp/gnus/gnus-search.el (gnus-search-indexed-search-command): Had
      named it incorrectly. Also switch to using nconc.
---
 lisp/gnus/gnus-search.el | 21 ++++++++++-----------
 1 file changed, 10 insertions(+), 11 deletions(-)

diff --git a/lisp/gnus/gnus-search.el b/lisp/gnus/gnus-search.el
index 37fc197..886905e 100644
--- a/lisp/gnus/gnus-search.el
+++ b/lisp/gnus/gnus-search.el
@@ -1533,19 +1533,18 @@ fudges a relevancy score of 100."
     (setenv "LC_MESSAGES" "C")
     (cl-call-next-method)))
 
-(cl-defmethod search-indexed-search-command ((engine gnus-search-namazu)
-                                            (qstring string)
-                                            query &optional _groups)
+(cl-defmethod gnus-search-indexed-search-command ((engine gnus-search-namazu)
+                                                 (qstring string)
+                                                 query &optional _groups)
   (let ((max (alist-get 'limit query)))
     (with-slots (switches index-dir) engine
-      `("-q"                           ; don't be verbose
-       "-a"                            ; show all matches
-       "-s"                            ; use short format
-       ,(if max (format "--max=%d" max) "")
-       ,@switches
-       ,qstring                        ; the query, in namazu format
-       ,index-dir                      ; index directory
-       ))))
+      (nconc
+       (list "-q"                      ; don't be verbose
+            "-a"                       ; show all matches
+            "-s")                      ; use short format
+       (when max (list (format "--max=%d" max)))
+       switches
+       (list qstring index-dir)))))
 
 (cl-defmethod gnus-search-indexed-extract ((engine gnus-search-namazu))
   "Extract a single message result for Namazu.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]