From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Dmitry Gutov Newsgroups: gmane.emacs.bugs Subject: bug#71049: async-shell-command ends with "Process *Async Shell Command* finished" when remote "direct-async-process" Date: Wed, 29 May 2024 23:40:28 +0300 Message-ID: References: <3a497741-2ad0-4919-b7c9-cdb36b0eb455@gutov.dev> <87ttinfgoa.fsf@gmx.de> <861q5r2ric.fsf@gnu.org> <87o78vf9l2.fsf@gmx.de> <86sey711m6.fsf@gnu.org> <221919a1-950e-4ef3-975d-f86078d8e105@gutov.dev> <87wmnidv3u.fsf@gmx.de> <25dad14a-397c-4052-908c-121e40bbef51@gutov.dev> <877cfhubyd.fsf@gmx.de> <608acf89-a1f9-4151-9f53-99962af87688@gutov.dev> <87jzjhvnbw.fsf@gmx.de> <50900208-34b8-4b7c-90fc-8796da6bccd6@gutov.dev> <87cyp9vlb1.fsf@gmx.de> <87fru4u06a.fsf@gmx.de> <7989cd21-7808-4416-ab0a-92e5da869a36@gutov.dev> <861q5ku956.fsf@gnu.org> <86wmncss4i.fsf@gnu.org> <0ebb5a51-8634-4f65-a384-79f82592e339@gutov.dev> <87h6egecqn.fsf@gmx.de> <727a50c7-0e50-429e-9f9a-78b5b29ff405@gutov.dev> <875xuwea52.fsf@gmx.de> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="34415"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Mozilla Thunderbird Cc: Eli Zaretskii , 71049@debbugs.gnu.org To: Michael Albinus Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Wed May 29 22:41:04 2024 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 1sCQ6Z-0008ib-FW for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 29 May 2024 22:41:04 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1sCQ6P-0002KG-H6; Wed, 29 May 2024 16:40:53 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1sCQ6O-0002K7-U6 for bug-gnu-emacs@gnu.org; Wed, 29 May 2024 16:40:52 -0400 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1sCQ6O-000092-Kr for bug-gnu-emacs@gnu.org; Wed, 29 May 2024 16:40:52 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1sCQ6Y-0002US-Gu for bug-gnu-emacs@gnu.org; Wed, 29 May 2024 16:41:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Dmitry Gutov Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 29 May 2024 20:41:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 71049 X-GNU-PR-Package: emacs Original-Received: via spool by 71049-submit@debbugs.gnu.org id=B71049.17170152509535 (code B ref 71049); Wed, 29 May 2024 20:41:02 +0000 Original-Received: (at 71049) by debbugs.gnu.org; 29 May 2024 20:40:50 +0000 Original-Received: from localhost ([127.0.0.1]:53387 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sCQ6M-0002Ti-Fi for submit@debbugs.gnu.org; Wed, 29 May 2024 16:40:50 -0400 Original-Received: from fhigh3-smtp.messagingengine.com ([103.168.172.154]:33755) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sCQ6J-0002TI-HP for 71049@debbugs.gnu.org; Wed, 29 May 2024 16:40:48 -0400 Original-Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailfhigh.nyi.internal (Postfix) with ESMTP id 50CB81140113; Wed, 29 May 2024 16:40:32 -0400 (EDT) Original-Received: from mailfrontend1 ([10.202.2.162]) by compute1.internal (MEProxy); Wed, 29 May 2024 16:40:32 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gutov.dev; h=cc :cc:content-transfer-encoding:content-type:content-type:date :date:from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:subject:subject:to:to; s=fm3; t=1717015232; x=1717101632; bh=cOtRrX8H+Uf3w3WsfiAg00jHCNgVFK8iMRPucVYjtsw=; b= F+1E5LlnDzmEl7y1uHbo5Egfb1lSGDagWPoQd/48C0KkVffenjeMCIn5ON4xCkU5 Vv8Grhhuk86f+4KFUglexLVR5iM6O7Jr9XtierdEhSSl32/hTv1Jm/ymyjoxMhVb P1/yQrxEhizHuJrNEkjQT4mXgw4aDm4c8kEIV0FZajOg8MYxylr9NKW0HsI1blMs EqyD7PwiLjTy4F9AWsjDhRpYwvIsb/hieQMZOBr+5x403NGPt0Jivv1LtEFtVF/O wXmJnWvqN/SDjpoj0y0f5+1Y5UYfEespQycLBHFdw61RsVFgSvNIg0wPUaUF+0fZ z/x8h1SNWcSFqfSgBSrY3g== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding :content-type:content-type:date:date:feedback-id:feedback-id :from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:subject:subject:to:to:x-me-proxy:x-me-proxy :x-me-sender:x-me-sender:x-sasl-enc; s=fm1; t=1717015232; x= 1717101632; bh=cOtRrX8H+Uf3w3WsfiAg00jHCNgVFK8iMRPucVYjtsw=; b=V Xg3po9nPGDtQCunOCUYN47o5mwevA7Hn4IVLSfGscW8xeGQrSlQ6wVz4XgGxtF/L nBauIn+bRfKtDFzehHvMSe92ERtuCN1vNyIazfvl7DBg6uZnJ/7eBm0re9AJZvAL XjrWmqgbgGm8T12n9cIt5JxO8MeIackqlDea3UdxkujwycAo5hjXJ50nxfCTh/tc YTAVbZq4Vi8l48g7G3LbCwQSRrtquGWlwZ6mFgwzEFGyIpbbVkL+Efv4HpMmJWM7 4VMjpVzv2vdImk9w3m+fABPKf6lHbLj3aeBJakPMmJlQ5xWwEcgeFV/KRGPyvbFe xN1ClPM9pktm7djrtQaKA== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvledrvdekuddgudeglecutefuodetggdotefrod ftvfcurfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfgh necuuegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmd enucfjughrpefkffggfgfuvfevfhfhjggtgfesthejredttddvjeenucfhrhhomhepffhm ihhtrhihucfiuhhtohhvuceoughmihhtrhihsehguhhtohhvrdguvghvqeenucggtffrrg htthgvrhhnpeetudeljeegheetgfehgeejkeeuhedvveeikeeufedtvddtveefhfdvveeg udejheenucevlhhushhtvghrufhiiigvpedtnecurfgrrhgrmhepmhgrihhlfhhrohhmpe gumhhithhrhiesghhuthhovhdruggvvh X-ME-Proxy: Feedback-ID: i0e71465a:Fastmail Original-Received: by mail.messagingengine.com (Postfix) with ESMTPA; Wed, 29 May 2024 16:40:30 -0400 (EDT) Content-Language: en-US In-Reply-To: <875xuwea52.fsf@gmx.de> 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-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:286179 Archived-At: On 29/05/2024 21:38, Michael Albinus wrote: > Dmitry Gutov writes: > >> On 29/05/2024 20:42, Michael Albinus wrote: >>> I made also the proposal to suppress reading >>> the remote history file for shell-command by default (performance!) >> How is that going to look, code-wise? > Not tested yet: > > > diff --git a/lisp/tramp.el b/lisp/tramp.el > index b2442f45..ba852cf6 100644 > --- a/lisp/tramp.el > +++ b/lisp/tramp.el > @@ -5260,7 +5260,17 @@ support symbolic links." > (with-current-buffer output-buffer > (setq mode-line-process '(":%s")) > (unless (eq major-mode 'shell-mode) > - (shell-mode)) > + ;; We set `tramp-histfile-override' to t in order to > + ;; suppress reading the remote history file by > + ;; default. Could be overridden by the user with a > + ;; connection-local setting. > + (let ((tramp-histfile-override t)) > + ;; `with-connection-local-application-variables' > + ;; exists since Emacs 29. Older Emacsen will use > + ;; default application `tramp'. > + (tramp-compat-with-connection-local-application-variables > + 'shell-command > + (shell-mode)))) > (set-process-filter p #'comint-output-filter) > (set-process-sentinel p #'shell-command-sentinel) > (when error-file Thank you. I haven't tested this personally either, but it seems like this is the behavior we will want by default. So the proposed solution should include it, I think.