From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Sean Whitton Newsgroups: gmane.emacs.bugs Subject: bug#46290: 28.0.50; repeat's ability to repeat complex commands is broken Date: Thu, 04 Feb 2021 10:47:22 -0700 Message-ID: <875z374ted.fsf@melete.silentflame.com> References: <878s844675.fsf@melete.silentflame.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="10643"; mail-complaints-to="usenet@ciao.gmane.io" To: Gregory Heytings , 46290@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Thu Feb 04 19:44:22 2021 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1l7jc5-0002cE-DR for geb-bug-gnu-emacs@m.gmane-mx.org; Thu, 04 Feb 2021 19:44:22 +0100 Original-Received: from localhost ([::1]:60298 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1l7jc4-0001gK-Eh for geb-bug-gnu-emacs@m.gmane-mx.org; Thu, 04 Feb 2021 13:44:20 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:56500) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1l7iic-0002tI-5T for bug-gnu-emacs@gnu.org; Thu, 04 Feb 2021 12:47:02 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]:58867) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1l7iib-00012l-Ug for bug-gnu-emacs@gnu.org; Thu, 04 Feb 2021 12:47:01 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1l7iib-00042t-Rr for bug-gnu-emacs@gnu.org; Thu, 04 Feb 2021 12:47:01 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Sean Whitton Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 04 Feb 2021 17:47:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 46290 X-GNU-PR-Package: emacs Original-Received: via spool by 46290-submit@debbugs.gnu.org id=B46290.161246080315528 (code B ref 46290); Thu, 04 Feb 2021 17:47:01 +0000 Original-Received: (at 46290) by debbugs.gnu.org; 4 Feb 2021 17:46:43 +0000 Original-Received: from localhost ([127.0.0.1]:42180 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1l7iiI-00042N-7s for submit@debbugs.gnu.org; Thu, 04 Feb 2021 12:46:43 -0500 Original-Received: from out5-smtp.messagingengine.com ([66.111.4.29]:49819) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1l7iiE-000428-Gn for 46290@debbugs.gnu.org; Thu, 04 Feb 2021 12:46:40 -0500 Original-Received: from compute4.internal (compute4.nyi.internal [10.202.2.44]) by mailout.nyi.internal (Postfix) with ESMTP id 283825C0060; Thu, 4 Feb 2021 12:46:33 -0500 (EST) Original-Received: from mailfrontend1 ([10.202.2.162]) by compute4.internal (MEProxy); Thu, 04 Feb 2021 12:46:33 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=spwhitton.name; h=from:to:subject:in-reply-to:references:date:message-id :mime-version:content-type; s=fm2; bh=UC37cGE7cunr71SSnrC6RYS8QN 5qBW2p93WnJW429gs=; b=j17vKHiiV6hSRM079mNKb9sxQGVe5TMyfPH+Juv9zT ncQo7ctEWHvAH7zdwn4l6WLEli41i1gU4HMtr+I14cUNtVZ5H8Q9PUPYu9EzJ7S2 l4QWK7jTH8Y7ianJQhBEJscrd2FE17BukegNQCNb0I+2j0n0vCBww/Iw5b0EJORc Qbu+pA2itGuykLOpwvUedm+SEtEZyuhbUESS9yh7ZcVj4Xey/7XuOSiJZHqHg8ZD a7G9sjageZsWcI9C5LI1hgyyPaGLJ1OmMtnlvCoomLePTW0v7q/HStxgWnqaBH3C Sd7e9KHf0dsLJR8Cxv0IizKt9gt1EhoeP63dqbYycMcQ== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-proxy :x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm2; bh=UC37cG E7cunr71SSnrC6RYS8QN5qBW2p93WnJW429gs=; b=Gx95LYDXCOHiQ7J9JwLb0u qXXZ2UR4BFz+piXM1jgRvWaEOobBa809Sax5Pu7QvQWb6I8RWbJHnhTdg0C/3DHl N+shTk+0zzzAj3fx8KFxHgU0J29PL9/nAHbrHqsY0FgGUWZnFBcVNk25Jxb81Q2C c4Yk/sFDadvik+tXAlNBUgdq1ha4Ncx+NXnzlo350mwHjQng/r4na1Ufd7Il5QQ2 Oljvu+aYEiTPMFialo/JYq8ECuf+bcJFFgvRi2MZSqlIRpQoqER/hfxdS0QOGqPO RExsZzdaqs8U/6tjYNRPfNNgtqbiPwFM9dF6J1yMpRNxK8HnrT6QOqxfBHg3VlYQ == X-ME-Sender: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgeduledrgeeggdeliecutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfghnecu uegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenuc fjughrpefhvffujghffffkgggtsehmtderredttddtnecuhfhrohhmpefuvggrnhcuhghh ihhtthhonhcuoehsphifhhhithhtohhnsehsphifhhhithhtohhnrdhnrghmvgeqnecugg ftrfgrthhtvghrnhepieffhfffudfhjefgfeeuleeutdevtdektdehiefgieetleevveek geduhedtudefnecuvehluhhsthgvrhfuihiivgeptdenucfrrghrrghmpehmrghilhhfrh homhepshhpfihhihhtthhonhesshhpfihhihhtthhonhdrnhgrmhgv X-ME-Proxy: In-Reply-To: X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:199319 Archived-At: --=-=-= Content-Type: text/plain On Thu 04 Feb 2021 at 08:30AM GMT, Gregory Heytings wrote: >> >> But secondly, it doesn't seem like the "Repeating %S" branch works at >> all. For if you type M-! date RET C-x z then you get prompted for a >> shell command, rather than date(1) just getting executed again right >> away. >> >> I added some debug printing to `repeat' and found that after M-! date >> RET, last-repeatable-command is set to shell-command, not >> exit-minibuffer. So perhaps the way that last-repeatable-command gets >> set has changed since this code in repeat.el was written? >> > > FWIW, the answer to that question seems to be positive. In Emacs 21 M-! > date RET C-x z repeats "date" without prompting again, in later Emacsen > you get prompted again for a shell command. Ah, thanks for testing. One possible fix is attached. It has the advantage of removing the list which needs to be kept updated, so it works immediately for repeating M-z and M-: -- Sean Whitton --=-=-= Content-Type: text/x-diff Content-Disposition: attachment; filename=0001-lisp-repeat.el-repeat-Fix-repeating-complex-commands.patch >From 60bde7beb317601c00d075f356a1b89877ad6104 Mon Sep 17 00:00:00 2001 From: Sean Whitton Date: Thu, 4 Feb 2021 10:42:21 -0700 Subject: [PATCH] * lisp/repeat.el (repeat): Fix repeating complex commands (bug#46290) --- lisp/repeat.el | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/lisp/repeat.el b/lisp/repeat.el index d488889348..795577c93f 100644 --- a/lisp/repeat.el +++ b/lisp/repeat.el @@ -239,9 +239,7 @@ recently executed command not bound to an input event\"." (car (memq last-command-event (listify-key-sequence repeat-on-final-keystroke)))))) - (if (memq last-repeatable-command '(exit-minibuffer - minibuffer-complete-and-exit - self-insert-and-exit)) + (if (eq last-repeatable-command (caar command-history)) (let ((repeat-command (car command-history))) (repeat-message "Repeating %S" repeat-command) (eval repeat-command)) -- 2.29.2 --=-=-=--