From unknown Fri Aug 15 18:46:04 2025 X-Loop: help-debbugs@gnu.org Subject: bug#37489: 27.0.50; Make `debbugs-gnu-search' work with `repeat-complex-command' Resent-From: Michael Heerdegen Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 23 Sep 2019 06:27:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 37489 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: 37489@debbugs.gnu.org X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.156921997625459 (code B ref -1); Mon, 23 Sep 2019 06:27:01 +0000 Received: (at submit) by debbugs.gnu.org; 23 Sep 2019 06:26:16 +0000 Received: from localhost ([127.0.0.1]:34924 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iCHnc-0006cY-8q for submit@debbugs.gnu.org; Mon, 23 Sep 2019 02:26:16 -0400 Received: from lists.gnu.org ([209.51.188.17]:41187) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iCHnb-0006cR-10 for submit@debbugs.gnu.org; Mon, 23 Sep 2019 02:26:15 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:56786) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1iCHnZ-0007wv-SZ for bug-gnu-emacs@gnu.org; Mon, 23 Sep 2019 02:26:14 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: ** X-Spam-Status: No, score=2.8 required=5.0 tests=BAYES_50,FREEMAIL_FROM, SPOOFED_FREEMAIL autolearn=disabled version=3.3.2 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1iCHnY-0002fn-Rs for bug-gnu-emacs@gnu.org; Mon, 23 Sep 2019 02:26:13 -0400 Received: from mout.web.de ([212.227.15.14]:55327) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1iCHnY-0002d1-ET for bug-gnu-emacs@gnu.org; Mon, 23 Sep 2019 02:26:12 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=web.de; s=dbaedf251592; t=1569219967; bh=R3ruujeQiO3S7fHehm7pfjX1NjVyI6y/6iI3zUbheMM=; h=X-UI-Sender-Class:From:To:Subject:Date; b=W96aQMo0vHWOtZp0WoDPFuxccM+kX3vLq2V9xVQmDfHjuzy5IKEM9MEI/P1qfJwaV 736LCyNe8GvqLqOEU0dzvGQ1LfqZs+6JTT3vVPydhwI7vHOwVvNB2iGCFCvsrW2YJr usalkX6NJ/xR4der4jNeh58IP1PU3D3Awz7zHFyw= X-UI-Sender-Class: c548c8c5-30a9-4db5-a2e7-cb6cb037b8f9 Received: from drachen.dragon ([94.216.136.59]) by smtp.web.de (mrweb003 [213.165.67.108]) with ESMTPSA (Nemesis) id 0LzKJV-1i8DCI2J73-014Qx2 for ; Mon, 23 Sep 2019 08:26:07 +0200 From: Michael Heerdegen Date: Mon, 23 Sep 2019 08:26:08 +0200 Message-ID: <87v9tjo7en.fsf@web.de> MIME-Version: 1.0 Content-Type: text/plain X-Provags-ID: V03:K1:ST9JDUzMHu1QpV2x6EWEUIrR52PLLwRcCakYfTMlNdC8GrWPaZK qyPkXX8i17W47AaWA96wl9Ze9FwfEIIFusUUqgh1EmlnET6nbRl3fwDjS8QI7NueDC5IgiD 7BvLE/XK9VRJENfOPdCMBPym7OvMXvFg1EueesUyq6kJ31CQCDmb4wbCzKNtIrpWoca9dB/ 7OpMIPpuyL2HNa1Uw5P4A== X-UI-Out-Filterresults: notjunk:1;V03:K0:oB6jVW1tr1I=:hTPuNA8pEBU8AbKy1RJV0M MjoJjMLgLi47TIZP+5I2KCGAAhTJbAa5owp7k2KrFKACI/EysqjvayoLpHxv24ql+Cr1zMeTP 1O9RJJcNnVDJDlaB46anW7PU+V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Dmep6P87TPDdp gtzDUhYCJEPAv7o8dF0uFAB5GB4CWidVqWacuz7Rzf9VMVtkPW5YMzt6dcwhRw5e9kraIN+Ea 7/C1hjDPs7DI47NLjBI3P+IE8w7u7VIHoIDihNKs1aD2xHRkgb7dN7NvNcwk= X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 212.227.15.14 X-Spam-Score: 0.6 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.4 (/) Hi, when I want to repeat searching bugs with `debbugs-gnu-search' and a similar query, I currently have to specify everything again. `repeat-complex-command' is no help since the command currently has no arguments. Could we please make it work with `repeat-complex-command'? The argument list of `debbugs-gnu-search' (currently empty) needs to contain all information gathered, that seems to be the value of `debbugs-gnu-current-query' and all arguments of the `debbugs-gnu' call. Then most of the current function body should be moved into the interactive form. In the body only `debbugs-gnu-current-query' should be let-bound to the first part of the function arguments, and `debbugs-gnu' should be called with the rest. TIA, Michael. From unknown Fri Aug 15 18:46:04 2025 X-Loop: help-debbugs@gnu.org Subject: bug#37489: 27.0.50; Make `debbugs-gnu-search' work with `repeat-complex-command' Resent-From: Michael Albinus Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 23 Sep 2019 13:27:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 37489 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: Michael Heerdegen Cc: 37489@debbugs.gnu.org Received: via spool by 37489-submit@debbugs.gnu.org id=B37489.15692451789472 (code B ref 37489); Mon, 23 Sep 2019 13:27:02 +0000 Received: (at 37489) by debbugs.gnu.org; 23 Sep 2019 13:26:18 +0000 Received: from localhost ([127.0.0.1]:35335 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iCOM5-0002Se-DA for submit@debbugs.gnu.org; Mon, 23 Sep 2019 09:26:18 -0400 Received: from mout.gmx.net ([212.227.17.20]:60655) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iCOM3-0002SP-IJ for 37489@debbugs.gnu.org; Mon, 23 Sep 2019 09:26:16 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1569245167; bh=kQ0F6HCV+tYh819yLLgNOWOwwFVWWCCnu9hKsSCe9s8=; h=X-UI-Sender-Class:From:To:Cc:Subject:References:Date:In-Reply-To; b=OxXQWMxLq7RtYoYIIbcP+F3oN/Rlefh54h78sctYiPrtpHwH8FwPtn1NAJr3JV/YH VhLrc2p3LdVvqmfgb0wlaYCorS1d8tvEwGA4r84gRd6IZUPH9+h1kAoVMUrWngfjyQ Z1kfPNb+/nWM6IAVLVr1Y16mpnCxwGUyJP2QojbA= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from detlef.gmx.de ([212.91.242.124]) by mail.gmx.com (mrgmx104 [212.227.17.168]) with ESMTPSA (Nemesis) id 1MqJqN-1hr81N3oCR-00nSj3; Mon, 23 Sep 2019 15:26:07 +0200 From: Michael Albinus References: <87v9tjo7en.fsf@web.de> Date: Mon, 23 Sep 2019 15:26:06 +0200 In-Reply-To: <87v9tjo7en.fsf@web.de> (Michael Heerdegen's message of "Mon, 23 Sep 2019 08:26:08 +0200") Message-ID: <87muevkutt.fsf@gmx.de> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Provags-ID: V03:K1:+UM9IdljtkoSYdOltaGQigpJkEAfdL7hlIo8hN9y/fjDTVT/jAR EQk6xqQVb00azirHIxuJiP/RPo9xREk7PVe6FgYuqfOBszOjKT5uE3ZcvV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ncxRvEOPN0VcWleXcyYybowSAX8l7I5GTJfQ1vv3lS8bgfWkV/xbTeWV83IiQRQqNwT/as 3LhkDxLUyVWOtvoauyDZ2exX9eEW0mw1vWoKmNbfGX+AOQaUBa+AhlEYGPSs530dKyCHZJK4v rPzgu/SGlZcc97MoUnLtTVFnMrnS6erTMXV4rI1hGOqd7TZ8X7DjPxIXLGQVmIc7TNamvayHx 2sMLQFmKvTo9Rq5mOogAE3UcUYBSXei0zhtLgUY/qQ/IrR17YjEktPf2AYPVOLzegQWjIRGwd BMjkhJGHgdfIZfWexgYFJHz3BK46ma6f9fKSApEGpUVAGGKSNJeA5UyE80Z0Ks6ph7+1RP5Fq /tK/G7KAPgYj5hNT0fGHnslmmXA6Wz4QWI+2tKLOLzcFxvr4IZCB4C8CmGxY= X-Spam-Score: -0.7 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) --=-=-= Content-Type: text/plain Michael Heerdegen writes: > Hi, Hi Michael, > when I want to repeat searching bugs with `debbugs-gnu-search' and a > similar query, I currently have to specify everything again. > `repeat-complex-command' is no help since the command currently has no > arguments. Could we please make it work with `repeat-complex-command'? > > The argument list of `debbugs-gnu-search' (currently empty) needs to > contain all information gathered, that seems to be the value of > `debbugs-gnu-current-query' and all arguments of the `debbugs-gnu' call. > > Then most of the current function body should be moved into the > interactive form. In the body only `debbugs-gnu-current-query' should > be let-bound to the first part of the function arguments, and > `debbugs-gnu' should be called with the rest. The appended patch shall do the job, you might test. However, I fear we will open a Pandora's box. We must set both debbugs-gnu-current-query and debbugs-gnu-current-filter, it depends on whether PHRASE is a string, or not. And even the allowed arguments in both cases are different. So it is very easy to make it wrong when editing the argument list. Even *I* would need to consult the implementation, in order to know what's allowed, and what's not. That's why the arguments were collected interactively only, so far. Anyway, I'm interested in your feedback whether that's the way to go. If yes, I would add some further sanity checks for QUERY, before callings debbugs-gnu. > TIA, > > Michael. Best regards, Michael. --=-=-= Content-Type: text/plain Content-Disposition: attachment Content-Transfer-Encoding: quoted-printable diff --git a/packages/debbugs/debbugs-gnu.el b/packages/debbugs/debbugs-gn= u.el index 82dd582dc..f70becc27 100644 =2D-- a/packages/debbugs/debbugs-gnu.el +++ b/packages/debbugs/debbugs-gnu.el @@ -417,172 +417,174 @@ be empty, in this case only the following attribut= es are used for search.")) ;;;###autoload -(defun debbugs-gnu-search () +(defun debbugs-gnu-search (phrase query severities packages archivedp) "Search for Emacs bugs interactively. Search arguments are requested interactively. The \"search phrase\" is used for full text search in the bugs database. Further key-value pairs are requested until an empty key is returned. If a key cannot be queried by a SOAP request, it is -marked as \"client-side filter\"." - (interactive) +marked as \"client-side filter\". - (unwind-protect - (let ((date-format - (eval-when-compile - (concat"\\([[:digit:]]\\{4\\}\\)-" - "\\([[:digit:]]\\{1,2\\}\\)-" - "\\([[:digit:]]\\{1,2\\}\\)"))) - key val1 val2 phrase severities packages archivedp) - - ;; Check for the phrase. - (setq phrase (read-string debbugs-gnu-phrase-prompt)) - (if (zerop (length phrase)) - (setq phrase nil) - (add-to-list 'debbugs-gnu-current-query (cons 'phrase phrase))) - ;; We suppress closed bugs if there is no phrase. - (setq debbugs-gnu-current-suppress - (if (not debbugs-gnu-suppress-closed) - nil - (null phrase))) - - ;; The other queries. - (catch :finished - (while t - (setq key (completing-read - "Enter attribute: " - (if phrase - (append - '("severity" "package" "tags" - "author" "date" "subject") - ;; Client-side filters. - (mapcar - (lambda (key) - (propertize - key 'face 'debbugs-gnu-done - 'help-echo "Client-side filter")) - '("status"))) - (append - '("severity" "package" "archive" "src" "status" "tag" - "owner" "submitter" "maint" "correspondent") - ;; Client-side filters. - (mapcar - (lambda (key) - (propertize - key 'face 'debbugs-gnu-done - 'help-echo "Client-side filter")) - '("date" "log_modified" "last_modified" - "found_date" "fixed_date" "unarchived" - "subject" "done" "forwarded" "msgid" "summary")))) - nil t)) - (cond - ;; Server-side queries. - ((equal key "severity") - (setq - severities - (completing-read-multiple - "Enter severities: " debbugs-gnu-all-severities nil t - (mapconcat #'identity debbugs-gnu-default-severities ",")))) - - ((equal key "package") - (setq - packages - (completing-read-multiple - "Enter packages: " debbugs-gnu-all-packages nil t - (mapconcat #'identity debbugs-gnu-default-packages ",")))) - - ((equal key "archive") - ;; We simplify, by assuming just archived bugs are requested. - (setq archivedp t)) - - ((member key '("src" "tag" "tags")) - (setq val1 (read-string (format "Enter %s: " key))) - (when (not (zerop (length val1))) - (add-to-list - 'debbugs-gnu-current-query (cons (intern key) val1)))) - - ((member - key '("author" "owner" "submitter" "maint" "correspondent")) - (setq val1 (read-string "Enter email address: ")) - (when (not (zerop (length val1))) - (add-to-list - 'debbugs-gnu-current-query - (cons (intern (if (equal key "author") "@author" key)) val1)))) - - ;; Client-side filters. - ((equal key "status") - (setq - val1 - (completing-read - (format "Enter status%s: " - (if (null phrase) "" " (client-side filter)")) - '("open" "forwarded" "done") nil t)) - (when (not (zerop (length val1))) - (if (null phrase) - (add-to-list - 'debbugs-gnu-current-query (cons (intern key) val1)) - (add-to-list - 'debbugs-gnu-current-filter (cons 'pending val1))))) - - ((member key '("date" "log_modified" "last_modified" - "found_date" "fixed_date" "unarchived")) - (setq val1 - (debbugs-gnu-calendar-read - (format "Enter %s before YYYY-MM-DD%s: " - key (if phrase "" " (client-side filter)")) - (lambda (x) - (string-match (concat "^\\(" date-format "\\|\\)$") x)))) - (if (string-match date-format val1) - (setq val1 (floor - (float-time - (encode-time - 0 0 0 - (string-to-number (match-string 3 val1)) - (string-to-number (match-string 2 val1)) - (string-to-number (match-string 1 val1)))))) - (setq val1 nil)) - (setq val2 - (debbugs-gnu-calendar-read - (format "Enter %s after YYYY-MM-DD%s: " - key (if phrase "" " (client-side filter)")) - (lambda (x) - (string-match (concat "^\\(" date-format "\\|\\)$") x)))) - (if (string-match date-format val2) - (setq val2 (floor - (float-time - (encode-time - 0 0 0 - (string-to-number (match-string 3 val2)) - (string-to-number (match-string 2 val2)) - (string-to-number (match-string 1 val2)))))) - (setq val2 nil)) - (when (or val1 val2) - (add-to-list - (if phrase - 'debbugs-gnu-current-query 'debbugs-gnu-current-filter) - (cons (intern - (if (and phrase (equal key "date")) "@cdate" key)) - (cons val1 val2))))) - - ;; "subject", "done", "forwarded", "msgid", "summary". - ((not (zerop (length key))) - (setq val1 - (funcall - (if phrase 'read-string 'read-regexp) - (format "Enter %s%s: " - key (if phrase "" " (client-side filter)")))) - (when (not (zerop (length val1))) - (add-to-list - (if phrase - 'debbugs-gnu-current-query 'debbugs-gnu-current-filter) - (cons (intern key) val1)))) - - ;; The End. - (t (throw :finished nil))))) - - ;; Do the search. - (debbugs-gnu severities packages archivedp) - (when (called-interactively-p 'interactive) - (message "Search finished"))))) +When using interactively, use \\[repeat-complex-command] after +this command for reusing the argument list. Be careful in +editing the arguments, because the allowed attributes for QUERY +depend on PHRASE being a string, or nil." + (interactive + (let ((date-format + (eval-when-compile + (concat"\\([[:digit:]]\\{4\\}\\)-" + "\\([[:digit:]]\\{1,2\\}\\)-" + "\\([[:digit:]]\\{1,2\\}\\)"))) + key val1 val2 phrase query severities packages archivedp) + + ;; Check for the phrase. + (setq phrase (read-string debbugs-gnu-phrase-prompt)) + (when (zerop (length phrase)) + (setq phrase nil)) + + ;; The other queries. + (catch :finished + (while t + (setq key (completing-read + "Enter attribute: " + (if phrase + (append + '("severity" "package" "tags" + "author" "date" "subject") + ;; Client-side filters. + (mapcar + (lambda (key) + (propertize + key 'face 'debbugs-gnu-done + 'help-echo "Client-side filter")) + '("status"))) + (append + '("severity" "package" "archive" "src" "status" "tag" + "owner" "submitter" "maint" "correspondent") + ;; Client-side filters. + (mapcar + (lambda (key) + (propertize + key 'face 'debbugs-gnu-done + 'help-echo "Client-side filter")) + '("date" "log_modified" "last_modified" + "found_date" "fixed_date" "unarchived" + "subject" "done" "forwarded" "msgid" "summary")))) + nil t)) + (cond + ;; Server-side queries. + ((equal key "severity") + (setq + severities + (completing-read-multiple + "Enter severities: " debbugs-gnu-all-severities nil t + (mapconcat #'identity debbugs-gnu-default-severities ",")))) + + ((equal key "package") + (setq + packages + (completing-read-multiple + "Enter packages: " debbugs-gnu-all-packages nil t + (mapconcat #'identity debbugs-gnu-default-packages ",")))) + + ((equal key "archive") + ;; We simplify, by assuming just archived bugs are requested. + (setq archivedp t)) + + ((member key '("src" "tag" "tags")) + (setq val1 (read-string (format "Enter %s: " key))) + (when (not (zerop (length val1))) + (push (cons (intern key) val1) query))) + + ((member + key '("author" "owner" "submitter" "maint" "correspondent")) + (setq val1 (read-string "Enter email address: ")) + (when (not (zerop (length val1))) + (push + (cons (intern (if (equal key "author") "@author" key)) val1) + query))) + + ;; Client-side filters. + ((equal key "status") + (setq + val1 + (completing-read + (format "Enter status%s: " + (if (null phrase) "" " (client-side filter)")) + '("open" "forwarded" "done") nil t)) + (when (not (zerop (length val1))) + (push (cons (if (null phrase) (intern key) 'pending) val1) query))) + + ((member key '("date" "log_modified" "last_modified" + "found_date" "fixed_date" "unarchived")) + (setq val1 + (debbugs-gnu-calendar-read + (format "Enter %s before YYYY-MM-DD%s: " + key (if phrase "" " (client-side filter)")) + (lambda (x) + (string-match (concat "^\\(" date-format "\\|\\)$") x)))) + (if (string-match date-format val1) + (setq val1 (floor + (float-time + (encode-time + 0 0 0 + (string-to-number (match-string 3 val1)) + (string-to-number (match-string 2 val1)) + (string-to-number (match-string 1 val1)))))) + (setq val1 nil)) + (setq val2 + (debbugs-gnu-calendar-read + (format "Enter %s after YYYY-MM-DD%s: " + key (if phrase "" " (client-side filter)")) + (lambda (x) + (string-match (concat "^\\(" date-format "\\|\\)$") x)))) + (if (string-match date-format val2) + (setq val2 (floor + (float-time + (encode-time + 0 0 0 + (string-to-number (match-string 3 val2)) + (string-to-number (match-string 2 val2)) + (string-to-number (match-string 1 val2)))))) + (setq val2 nil)) + (when (or val1 val2) + (push + (cons (intern (if (and phrase (equal key "date")) "@cdate" key)) + (cons val1 val2)) + query))) + + ;; "subject", "done", "forwarded", "msgid", "summary". + ((not (zerop (length key))) + (setq val1 + (funcall + (if phrase 'read-string 'read-regexp) + (format "Enter %s%s: " + key (if phrase "" " (client-side filter)")))) + (when (not (zerop (length val1))) + (push (cons (intern key) val1) query))) + + ;; The End. + (t (throw :finished nil))))) + + ;; The arguments. + (list phrase query severities packages archivedp))) + + + ;; We suppress closed bugs if there is no phrase. + (setq debbugs-gnu-current-suppress + (if (not debbugs-gnu-suppress-closed) + nil + (null phrase))) + + ;; Set phrase and query. + (if phrase + (setq debbugs-gnu-current-query + (append (list (cons 'phrase phrase)) query)) + (setq debbugs-gnu-current-filter query)) + + ;; Do the search. + (debbugs-gnu severities packages archivedp) + (message "Search finished")) ;;;###autoload (defun debbugs-gnu-patches () --=-=-=-- From debbugs-submit-bounces@debbugs.gnu.org Mon Sep 23 09:26:48 2019 Received: (at control) by debbugs.gnu.org; 23 Sep 2019 13:26:48 +0000 Received: from localhost ([127.0.0.1]:35338 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iCOMa-0002Td-A3 for submit@debbugs.gnu.org; Mon, 23 Sep 2019 09:26:48 -0400 Received: from mout.gmx.net ([212.227.15.15]:52773) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iCOMY-0002TL-R3 for control@debbugs.gnu.org; Mon, 23 Sep 2019 09:26:47 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1569245198; bh=WXWKs5x3drFo+xgIHozG6nQWDAbtdGaDt1PLB+G6PZ8=; h=X-UI-Sender-Class:Date:To:From:Subject; b=amIBYgF6u6BsRh5+5087PaeqsE31jwqIzk2oKXKmlTHwhRGVuz1uHTrzybFfhUjVx aeI4gIJLex1/31zlcymaRSwWyioo6acNN1Ld6/s48zLecrvIulqXKFhrG+KlDy2gk4 KoZoTTotAXA5JGtSnOu7DRanV3rzvhx87DcI9Od4= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from detlef.gmx.de ([212.91.242.124]) by mail.gmx.com (mrgmx004 [212.227.17.190]) with ESMTPSA (Nemesis) id 1MrQIv-1hsEyP2o8F-00oWDi for ; Mon, 23 Sep 2019 15:26:38 +0200 Date: Mon, 23 Sep 2019 15:26:37 +0200 Message-Id: <87lfufkusy.fsf@gmx.de> To: control@debbugs.gnu.org From: Michael Albinus Subject: control message for bug #37489 X-Provags-ID: V03:K1:v26G9B+fMsrvjJx7VaWvP//+Yt7FK3tM/J/+NbN+d149TctYfkq FADmD9wzuVy05bCNyjN7gNb+9gHcLv28dA4C9Y7QsJoklEUVh49jXhuW/yoi9M/IWues182 Bt0rN2JNH9DjEoPoWeAaDOOtPaTwH48roie0EE2vHFgxzgGDciqkfVrdiD7mN5zetvHZU3B M/wkL95bQ0j0itUhT36bg== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:dhOQkYq0vcI=:R8CoHB44TXhIFrnIhKXfTb eIcrhOhgH1lzykT8Vn3NSz+JJ7i2EYdTes2Vqe3Vw0FbHDPYvmulyZYJ6SIa7xyTFo5JX7lea AoCvjjL0ypxn/c9V5xvXwAGmyWT4/PGAUE0CqOdmh/SRrSVQR79ngGgWTC2iXp9MHMWEIHEeK QyzWPIsITWVNheTXKNCCTDl0E6J2uUTgEfqUPqA7ueONTx1ZdVo81whUVoFxEgjGKX5DWk5LG Et+vE4UlAXSPQGdSiqRRQ4M6bZfbRu6pGhAisonmoBlRsMv36HS+0inuGPe/FylrcjRq44SMQ fqhKEbYvoBMH4EfP0RnCDCnPVv/JOYmcCX6e8AguQ79tNU1qzVdDxIrjrJEjgKdXeEctuJesZ 0VFfdwcpAIaPxj8bswYmFf8Q3A2Mv6W4OeP1rzQfXnDofxGNLWgVgzpszhJc9yLD0FZ/FodgS JRuV3+YkgluIPxhzG8/xqHcw4RBziqv+vCSKN/TATgx33iaiSbIyVUK3Pj78IX4J70fiVTGIa +FZo/g/6Je4Htbjm5aQheVpSVcut7oKUiJImxw8x4l9TBZHGeH9X37yKquVFhKwVatV2ga19S Q9vYJDPB2F0uqLTH/QnVu/5TR4OcsFjCO5oPMQ1C64jkvqH8/kTPjK9eRxFkO8S8uUPwYehg3 ggMek20JynmGlJLMNO5fUew207HH+mtZBaQTdNnsKPLs8RaJNaNnopmkn1U5RrL4u34HQhOTM lvr4Tcu6/qXCUK0R0cBXq72OyOPf5QgjXWsAlMhG8ftnjcRCYmKNBp7iaLEAnbGX64Ywf2/AF 6B9fKryyc+Bd8OeGcX9KqQ9sbPFH0VyCwumo4pLaAqgg+p+uT++RMnNMSc8Du/YTUejtuM0I3 R8eL4s5SJxDGJcsOshQBRX1BYK9SBrXRN2k4jsd7vCoxguS4yMsyG67mZR5bmtN185xgilL14 Xii4QyhYVnSzlYvaFWv/jDUnJkGgc9nbAOpQPQwi9jMX4fROLlMTNROWmoXqL23LQAg0Soh+k Y8KyPoiXU6obfY+QG/bLfaZldAgWuCoHhNWYbSiX0+NhZdWPDFr34RLXa0rF7NW9vBjnxMLFm /lrCMydyiWZOIrDpho+1gQ+fKbmOtNEdA7QLAvClcy+MuewMK6a4cndLFK4LrIgd7N1jJNDw/ MS5GPUrlDHZStKXIIzxlivDcm+J4pg9GI+zmK8nV1P5oYFVn3aExYQeZmYRYLuapXdu0p7ZPg 2ks5Cj9SikD135mS+k+EOZLNID3jjJjhQUyg9sFXIOkdyn1vt2+IC8c84Xsc= X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) tags 37489 + patch quit From debbugs-submit-bounces@debbugs.gnu.org Mon Sep 23 09:27:23 2019 Received: (at control) by debbugs.gnu.org; 23 Sep 2019 13:27:24 +0000 Received: from localhost ([127.0.0.1]:35344 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iCON9-0002VD-Jo for submit@debbugs.gnu.org; Mon, 23 Sep 2019 09:27:23 -0400 Received: from mout.gmx.net ([212.227.15.19]:44869) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iCON5-0002Uq-Bd for control@debbugs.gnu.org; Mon, 23 Sep 2019 09:27:22 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1569245231; bh=0w64TijvKeS0+Ve3aSeaWwXD1L8Hvb04PpEkvDGLA8A=; h=X-UI-Sender-Class:Date:To:From:Subject; b=iz42LWBzj8Pkh2PIiEbftxVeifAvUvCCMw4VTDD/rFS0U8N7eC0jm8+bIGIazDBzV g6BvSbOH8FZwl0pnxBsC9JKlIhI6dvu5GiEscmNCKqJbGvuIAvcUFNXyMeOA9Tu4NT 4M95Lfgjzo/JYM65hee5uK1IZEbFuPxcmR+OoOzY= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from detlef.gmx.de ([212.91.242.124]) by mail.gmx.com (mrgmx005 [212.227.17.190]) with ESMTPSA (Nemesis) id 1MFbW0-1iP5ft1ayk-00H3Gk for ; Mon, 23 Sep 2019 15:27:11 +0200 Date: Mon, 23 Sep 2019 15:27:09 +0200 Message-Id: <87k19zkus2.fsf@gmx.de> To: control@debbugs.gnu.org From: Michael Albinus Subject: control message for bug #37489 X-Provags-ID: V03:K1:eKlQLNQKgOtFKkt6T6mNGeGhtuijyOnrE4XHvnyiRinXxN4G/2i xgq0sh2Jh7EfTfz0cTLpCmfKycjojO4pM1DCW4ruZf0SFacWeRTcadPA4FckjMBh491neuE TnQG+PH6gBylcsDufC7umdQ3slNxR6ikOmD9xaJCL1cq3CwUlWXsc2ort48gcagNh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1FtYGKTpVQ3RS1ajw78p3e/pRUKbS9NXPjkUG0KwugC/HwhrQTg4by2oncYZTHy xRyBVlI58l4swkdIv8f9uM23tijn12OUEdF3pNtJeA17f43BpkgT52ZQ9EGJFDhDXn+xSGHAH gJenReZCfzPHP0jCaT8YM9oEjLa46n6Bbvt/BOTU2kI+12X39pouXo6xcck2xSnF7E1aYkwPN VK8Jdc1mZbp2TRMs7iptuFJX3d340g+UN3/qTfb6x5tJOveLnBYC2nM/1skTxNxefGn+Erjmi J+36wbQG5qiJyQQ6xhO3aUn7+NkqYKhPt1DAvATuU+hH3Z3ZuBl5uuFyib9o= X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) severity 37489 wishlist quit From unknown Fri Aug 15 18:46:04 2025 X-Loop: help-debbugs@gnu.org Subject: bug#37489: 27.0.50; Make `debbugs-gnu-search' work with `repeat-complex-command' Resent-From: Michael Heerdegen Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 24 Sep 2019 03:02:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 37489 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch To: Michael Albinus Cc: 37489@debbugs.gnu.org Received: via spool by 37489-submit@debbugs.gnu.org id=B37489.156929406226591 (code B ref 37489); Tue, 24 Sep 2019 03:02:02 +0000 Received: (at 37489) by debbugs.gnu.org; 24 Sep 2019 03:01:02 +0000 Received: from localhost ([127.0.0.1]:37367 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iCb4X-0006uc-PM for submit@debbugs.gnu.org; Mon, 23 Sep 2019 23:01:02 -0400 Received: from mout.web.de ([217.72.192.78]:50935) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iCb4V-0006uL-Bh for 37489@debbugs.gnu.org; Mon, 23 Sep 2019 23:01:00 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=web.de; s=dbaedf251592; t=1569294050; bh=4goLQ3rwUXhYlrViatBCenfWz6x1f6o0ezikKAF0INo=; h=X-UI-Sender-Class:From:To:Cc:Subject:References:Date:In-Reply-To; b=gz0EVTRb8jbNhlR96Mn//KHSQITIpt5CDTVaMAjEUa7zs5G03aahz+z8xnwXZroUH iRrTNKO7KP72y4YP5I7x+ZUkKTu5/FzepUPDPFGtyBxR4y4ZHOJ6J6NceBsEIO9mGW c8r9aSqvHoskLlA7dmayftcXA0w/B+BT+gxFWWwo= X-UI-Sender-Class: c548c8c5-30a9-4db5-a2e7-cb6cb037b8f9 Received: from drachen.dragon ([94.216.136.59]) by smtp.web.de (mrweb103 [213.165.67.124]) with ESMTPSA (Nemesis) id 0MY712-1ihVz82iO0-00Uuqk; Tue, 24 Sep 2019 05:00:50 +0200 From: Michael Heerdegen References: <87v9tjo7en.fsf@web.de> <87muevkutt.fsf@gmx.de> Date: Tue, 24 Sep 2019 05:00:50 +0200 In-Reply-To: <87muevkutt.fsf@gmx.de> (Michael Albinus's message of "Mon, 23 Sep 2019 15:26:06 +0200") Message-ID: <87ef064cv1.fsf@web.de> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Provags-ID: V03:K1:jIQ8OJUoMmii2pdZTl6uD+btUyWKx1CeC/XSyv47VRrLYSBpe7m hFOTNIgac6CiB6sQzeKFFEAaOxNFovATjB8kK0+vyt8TYTSdwHSANH8jQ1fYKMieyWCv8fW 9r93P+qYejiq3hZ65vKDZ1FmzqGIUhJGKtt7n9A41YUaWmBfS4hAL0WND8z/49tamlYsbcG SoVTdnqWKcp2FSLy50kFg== X-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L/vJhPih1MzCG2QxrGIqsKxGj 9PZe+ckOd6sEpEubqww6ScMw+OMtLqlk05QEq6YOeV+Wee6NvsBRgMXfTKCQSCZylqRmmyX8l DNWj5A6co592ADiL8/Z7czrdMHRZVk2KQ5KTzersedCABOM1wKvQr69y1cmR9/2rpXwXadtBz FuZbxw3CgqiqVCIKAEK7yJFT48ciATBuUdJfTsVCQgvfHQWJObc0/iJJIVdaSPgVfMyGj3J1n RK7mvNkyIzKFotPyinlN5nNEevf3/JviE8Htyz5z/VaXi8TOcRr/6j5rO0k0= X-Spam-Score: -0.7 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) Michael Albinus writes: > The appended patch shall do the job, you might test. Seems to work fine, yes, thanks. > However, I fear we will open a Pandora's box. We must set both > debbugs-gnu-current-query and debbugs-gnu-current-filter, it depends > on whether PHRASE is a string, or not. And even the allowed arguments > in both cases are different. So it is very easy to make it wrong when > editing the argument list. Even *I* would need to consult the > implementation, in order to know what's allowed, and what's > not. I don't find it this problematic. It's ok when not all combinations of arguments are allowed. But instead of consulting the implementation, it would of course be better to describe limitations in the docstring. If it gets too complicated, maybe the list of arguments could be changed to reflect the implementation even more. Anyway, the patch is all that I wanted. If the command barks the last resort is to go through the queries again, which I have to do now anyway. > I would add some further sanity checks for QUERY, before callings > debbugs-gnu. That might be appropriate, but adding some details to the docstring in addition along the way might not be wrong, too. You don't even need to explain each argument in detail (maybe you could even point to other functions' docstring for that?), just enough to let me know what would not work. FWIW, I never called the command with an empty phrase, since I didn't know that this is allowed and even then I would rather expect that the server would blacklist me :-) Regards, Michael. From unknown Fri Aug 15 18:46:04 2025 MIME-Version: 1.0 X-Mailer: MIME-tools 5.505 (Entity 5.505) X-Loop: help-debbugs@gnu.org From: help-debbugs@gnu.org (GNU bug Tracking System) To: Michael Heerdegen Subject: bug#37489: closed (Re: bug#37489: 27.0.50; Make `debbugs-gnu-search' work with `repeat-complex-command') Message-ID: References: <877e5y6vap.fsf@gmx.de> <87v9tjo7en.fsf@web.de> X-Gnu-PR-Message: they-closed 37489 X-Gnu-PR-Package: emacs X-Gnu-PR-Keywords: patch Reply-To: 37489@debbugs.gnu.org Date: Tue, 24 Sep 2019 06:53:02 +0000 Content-Type: multipart/mixed; boundary="----------=_1569307982-7380-1" This is a multi-part message in MIME format... ------------=_1569307982-7380-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Your bug report #37489: 27.0.50; Make `debbugs-gnu-search' work with `repeat-complex-comman= d' which was filed against the emacs package, has been closed. The explanation is attached below, along with your original report. If you require more details, please reply to 37489@debbugs.gnu.org. --=20 37489: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D37489 GNU Bug Tracking System Contact help-debbugs@gnu.org with problems ------------=_1569307982-7380-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at 37489-done) by debbugs.gnu.org; 24 Sep 2019 06:52:11 +0000 Received: from localhost ([127.0.0.1]:37488 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iCegF-0001ty-4t for submit@debbugs.gnu.org; Tue, 24 Sep 2019 02:52:11 -0400 Received: from mout.gmx.net ([212.227.17.21]:46925) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iCegD-0001tl-12 for 37489-done@debbugs.gnu.org; Tue, 24 Sep 2019 02:52:09 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1569307921; bh=+mzelRfjlO4L4U3HwHcJLQ5WM06VyDQK12xr/qbO67g=; h=X-UI-Sender-Class:From:To:Cc:Subject:References:Date:In-Reply-To; b=ZqlAdZ7z4V0zaMgfhqnfYTcsMYfwLvdVXCIY8nq6rMBkomReEWCLofeLneC8ZR0FD F7UFBuOo1b9bhYp59ybDHZyPgEgOARBZ0jIC6KARgfuBdebcogjdt/MajQubnadscW ONCGKNTHWR+zSd/I9zlChhFez9U+HJoQRyMbgyiY= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from detlef.gmx.de ([212.86.50.177]) by mail.gmx.com (mrgmx105 [212.227.17.168]) with ESMTPSA (Nemesis) id 1M4s0t-1iE1ix348V-001w3o; Tue, 24 Sep 2019 08:52:00 +0200 From: Michael Albinus To: Michael Heerdegen Subject: Re: bug#37489: 27.0.50; Make `debbugs-gnu-search' work with `repeat-complex-command' References: <87v9tjo7en.fsf@web.de> <87muevkutt.fsf@gmx.de> <87ef064cv1.fsf@web.de> Date: Tue, 24 Sep 2019 08:51:58 +0200 In-Reply-To: <87ef064cv1.fsf@web.de> (Michael Heerdegen's message of "Tue, 24 Sep 2019 05:00:50 +0200") Message-ID: <877e5y6vap.fsf@gmx.de> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Provags-ID: V03:K1:K085Iy4u5mYZLGmDZwtCQs6MptisNlOYe1V+IBYSUH2Iid+5NVM QjLkZIZxVLz+8NlN1XbFF3IwNXi7C5t6w959D7bs+rKu2M3GXZMOkLse9HcVgz35NNMXY7R IPohWmHUHkJmJOBq1NrD35eK8gpaAqe/UCAAISW3lV8UTU2SeT6UmIT+V0h4chYf34zdUSM TTucPHcbtXxOQ7sBrTKdQ== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:GDcDpuOFcNg=:6Kv7uuHkmHjfmWU/mZ5pKj puzab/b3MPxrIKPPBZc+S1I8O35qSrARFzxmVGr3jP7ni8XnTdR/X3GnvPTy+iBzhvbWntBM6 c+PAN9XwKm8BWiqAVcOhggZhj9Ausg0DzX4FG59/sbbd4ywnrDOT0VXQJDNZAdCE/TaxGJklI zyLUud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VR8VglFT7 uw02GjHrrKpzVmV6e2uy4+KuCKq5n7KdRLIjblJqHHMiC2J2sirdN2h9iGwU= X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 37489-done Cc: 37489-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) Michael Heerdegen writes: Hi Michael, >> The appended patch shall do the job, you might test. > > Seems to work fine, yes, thanks. Thanks for testing. There was still an error in the patch; it didn't distinguish between queries and filters. I have fixed this. >> However, I fear we will open a Pandora's box. We must set both >> debbugs-gnu-current-query and debbugs-gnu-current-filter, it depends >> on whether PHRASE is a string, or not. And even the allowed arguments >> in both cases are different. So it is very easy to make it wrong when >> editing the argument list. Even *I* would need to consult the >> implementation, in order to know what's allowed, and what's >> not. > > I don't find it this problematic. It's ok when not all combinations of > arguments are allowed. But instead of consulting the implementation, it > would of course be better to describe limitations in the docstring. If > it gets too complicated, maybe the list of arguments could be changed to > reflect the implementation even more. It's even more complex. There is the difference whether an argument is appropriate or not, depending on QUERY being a string or nil. But there is also the difference whether an argument is sent to the server, or whether the argument's discrimination is done client-side. The latter is much less performant. > Anyway, the patch is all that I wanted. If the command barks the last > resort is to go through the queries again, which I have to do now > anyway. > >> I would add some further sanity checks for QUERY, before callings >> debbugs-gnu. > > That might be appropriate, but adding some details to the docstring in > addition along the way might not be wrong, too. You don't even need to > explain each argument in detail (maybe you could even point to other > functions' docstring for that?), just enough to let me know what would > not work. FWIW, I never called the command with an empty phrase, since > I didn't know that this is allowed and even then I would rather expect > that the server would blacklist me :-) See the manual, it tells you :-) `debugs-gnu search' is designed to handle all of this interactively. Now, that we have arguments, and this command can be called like a function, I've added a reference to the docstring, pointing to the manual. Plus the promised sanity checks. I've pushed the changes to GNU ELPA. I've also released debbugs 0.20, because the solution for bug#36903, which was blocking the release, is expected to be applied in gnus. > Regards, > > Michael. Best regards, Michael. ------------=_1569307982-7380-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at submit) by debbugs.gnu.org; 23 Sep 2019 06:26:16 +0000 Received: from localhost ([127.0.0.1]:34924 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iCHnc-0006cY-8q for submit@debbugs.gnu.org; Mon, 23 Sep 2019 02:26:16 -0400 Received: from lists.gnu.org ([209.51.188.17]:41187) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iCHnb-0006cR-10 for submit@debbugs.gnu.org; Mon, 23 Sep 2019 02:26:15 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:56786) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1iCHnZ-0007wv-SZ for bug-gnu-emacs@gnu.org; Mon, 23 Sep 2019 02:26:14 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: ** X-Spam-Status: No, score=2.8 required=5.0 tests=BAYES_50,FREEMAIL_FROM, SPOOFED_FREEMAIL autolearn=disabled version=3.3.2 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1iCHnY-0002fn-Rs for bug-gnu-emacs@gnu.org; Mon, 23 Sep 2019 02:26:13 -0400 Received: from mout.web.de ([212.227.15.14]:55327) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1iCHnY-0002d1-ET for bug-gnu-emacs@gnu.org; Mon, 23 Sep 2019 02:26:12 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=web.de; s=dbaedf251592; t=1569219967; bh=R3ruujeQiO3S7fHehm7pfjX1NjVyI6y/6iI3zUbheMM=; h=X-UI-Sender-Class:From:To:Subject:Date; b=W96aQMo0vHWOtZp0WoDPFuxccM+kX3vLq2V9xVQmDfHjuzy5IKEM9MEI/P1qfJwaV 736LCyNe8GvqLqOEU0dzvGQ1LfqZs+6JTT3vVPydhwI7vHOwVvNB2iGCFCvsrW2YJr usalkX6NJ/xR4der4jNeh58IP1PU3D3Awz7zHFyw= X-UI-Sender-Class: c548c8c5-30a9-4db5-a2e7-cb6cb037b8f9 Received: from drachen.dragon ([94.216.136.59]) by smtp.web.de (mrweb003 [213.165.67.108]) with ESMTPSA (Nemesis) id 0LzKJV-1i8DCI2J73-014Qx2 for ; Mon, 23 Sep 2019 08:26:07 +0200 From: Michael Heerdegen To: bug-gnu-emacs@gnu.org Subject: 27.0.50; Make `debbugs-gnu-search' work with `repeat-complex-command' Date: Mon, 23 Sep 2019 08:26:08 +0200 Message-ID: <87v9tjo7en.fsf@web.de> MIME-Version: 1.0 Content-Type: text/plain X-Provags-ID: V03:K1:ST9JDUzMHu1QpV2x6EWEUIrR52PLLwRcCakYfTMlNdC8GrWPaZK qyPkXX8i17W47AaWA96wl9Ze9FwfEIIFusUUqgh1EmlnET6nbRl3fwDjS8QI7NueDC5IgiD 7BvLE/XK9VRJENfOPdCMBPym7OvMXvFg1EueesUyq6kJ31CQCDmb4wbCzKNtIrpWoca9dB/ 7OpMIPpuyL2HNa1Uw5P4A== X-UI-Out-Filterresults: notjunk:1;V03:K0:oB6jVW1tr1I=:hTPuNA8pEBU8AbKy1RJV0M MjoJjMLgLi47TIZP+5I2KCGAAhTJbAa5owp7k2KrFKACI/EysqjvayoLpHxv24ql+Cr1zMeTP 1O9RJJcNnVDJDlaB46anW7PU+Vg6W8Zkql5O7/1NpWpNoLsFQjdYZfVS9SLfEaKhIkHHhwIUM E+bsFBfhoboR20Xl4e2B3CLw+xWbBL53dXZWcLKxAoGlXpmcAzgR9B1DQPP09KadsWqaRc6hp Mu3ZGKLm7Km6Gx3ZM/3nJrpd6QgWCvqnrwXnoQVMD6f1ciugIbX+P+2Z1X9SHXFBgUN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Received-From: 212.227.15.14 X-Spam-Score: 0.6 (/) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.4 (/) Hi, when I want to repeat searching bugs with `debbugs-gnu-search' and a similar query, I currently have to specify everything again. `repeat-complex-command' is no help since the command currently has no arguments. Could we please make it work with `repeat-complex-command'? The argument list of `debbugs-gnu-search' (currently empty) needs to contain all information gathered, that seems to be the value of `debbugs-gnu-current-query' and all arguments of the `debbugs-gnu' call. Then most of the current function body should be moved into the interactive form. In the body only `debbugs-gnu-current-query' should be let-bound to the first part of the function arguments, and `debbugs-gnu' should be called with the rest. TIA, Michael. ------------=_1569307982-7380-1--