From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#58909: 29.0.50; [WIP PATCH] Deleting the last frame of an emacsclient doesn't ask to save Date: Mon, 31 Oct 2022 14:44:21 +0200 Message-ID: <83zgdcduxm.fsf@gnu.org> References: <9a70f868-ca50-52fc-af3e-23813af104f2@gmail.com> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="16087"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 58909@debbugs.gnu.org To: Jim Porter Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Mon Oct 31 13:45:26 2022 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 1opUAQ-00043A-6W for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 31 Oct 2022 13:45:26 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1opUA4-0004VZ-Ev; Mon, 31 Oct 2022 08:45:04 -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 1opUA3-0004UV-0I for bug-gnu-emacs@gnu.org; Mon, 31 Oct 2022 08:45:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1opUA2-0008Kw-N1 for bug-gnu-emacs@gnu.org; Mon, 31 Oct 2022 08:45:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1opUA2-0004qJ-ID for bug-gnu-emacs@gnu.org; Mon, 31 Oct 2022 08:45:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 31 Oct 2022 12:45:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 58909 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 58909-submit@debbugs.gnu.org id=B58909.166722028418549 (code B ref 58909); Mon, 31 Oct 2022 12:45:02 +0000 Original-Received: (at 58909) by debbugs.gnu.org; 31 Oct 2022 12:44:44 +0000 Original-Received: from localhost ([127.0.0.1]:39721 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1opU9k-0004p7-A2 for submit@debbugs.gnu.org; Mon, 31 Oct 2022 08:44:44 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:59048) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1opU9i-0004ou-Gg for 58909@debbugs.gnu.org; Mon, 31 Oct 2022 08:44:42 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1opU9d-0008BM-7t; Mon, 31 Oct 2022 08:44:37 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=qtef3QX1WyjwM4LBArarc2s82WljPdyuBkU5Fr5TDkM=; b=Yj7ck1jrgbBK 4q2Revwy0Oj+TLvohjeUlcqd1eExrBL0r9ZBr3dgDUfsyUnKfPOQ6fj27t2LHuE18PRbmpGjfNY3U cjXyAcyflXTM5DENV8tVPDqxtu6meaccoatV0/hZvqWg9lq08FMWhjXAXPyL/ckM3EsFBq4xw5CqQ f446olHCarv6R+iDA1qsysInBqSAa2ysmoKlUlrrBQgGlMeTvAG21vH4nNq8zRpdYqU5W7bTjRQyf qQBoO+7BpgKveBqCFe1dNCM+EW7azLM/xkhiM66goz1vtgAPLnALJg2zC2rUlScfeBHLIL9i4JYCY EyZO+ks6X4xRApCVlqDCzg==; Original-Received: from [87.69.77.57] (helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1opU9c-0003Ne-Nt; Mon, 31 Oct 2022 08:44:37 -0400 In-Reply-To: <9a70f868-ca50-52fc-af3e-23813af104f2@gmail.com> (message from Jim Porter on Sun, 30 Oct 2022 15:29:30 -0700) 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: , Original-Sender: "bug-gnu-emacs" Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:246678 Archived-At: > Date: Sun, 30 Oct 2022 15:29:30 -0700 > From: Jim Porter > > $ emacs -Q -f server-start > $ emacsclient -c foo.txt > > ;; type some random characters > > C-x # > ;; or... > C-x C-c > > In both cases, Emacs will ask to save foo.txt, though the prompts will > be slightly different. That's good, since whatever invoked "emacsclient > -c foo.txt" is likely waiting for the user to have saved that file. > > However, if you use 'C-x 5 0' instead, that terminates the Emacs client, > but *doesn't* prompt to save foo.txt. I think it should prompt in this > case too: all three of 'C-x #', 'C-x C-c', and 'C-x 5 0' have the effect > (in this simple case) of deleting the Emacs client and returning to the > calling process. (A user who wanted to bail out of an Emacs client > without saving should use 'sever-edit-abort' instead.) I'm uneasy with this incompatible behavior change. I can think of some legitimate use cases where "C-x 5 0" should not prompt, e.g., if the user intends to keep editing the file, and no application is waiting for the client to finish. Why break such flows? Deleting a frame does no harm as long as Emacs is still up and running after that, so IMO forcing the user to answer such a prompt could be an annoyance. Thanks.