From unknown Sun Jun 22 17:15:26 2025 X-Loop: help-debbugs@gnu.org Subject: bug#13801: [PATCH] Trivial fix for files.el Resent-From: Xue Fuqiao Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 24 Feb 2013 07:14:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 13801 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch To: 13801@debbugs.gnu.org X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.13616900287613 (code B ref -1); Sun, 24 Feb 2013 07:14:01 +0000 Received: (at submit) by debbugs.gnu.org; 24 Feb 2013 07:13:48 +0000 Received: from localhost ([127.0.0.1]:46465 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1U9VmN-0001yj-K8 for submit@debbugs.gnu.org; Sun, 24 Feb 2013 02:13:48 -0500 Received: from eggs.gnu.org ([208.118.235.92]:60988) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1U9VmK-0001yb-92 for submit@debbugs.gnu.org; Sun, 24 Feb 2013 02:13:45 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1U9Vko-0002Mj-Ic for submit@debbugs.gnu.org; Sun, 24 Feb 2013 02:12:12 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-102.6 required=5.0 tests=BAYES_00,FREEMAIL_FROM, RCVD_IN_DNSWL_LOW, T_DKIM_INVALID, USER_IN_WHITELIST autolearn=unavailable version=3.3.2 Received: from lists.gnu.org ([208.118.235.17]:54835) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1U9Vko-0002MT-Ez for submit@debbugs.gnu.org; Sun, 24 Feb 2013 02:12:10 -0500 Received: from eggs.gnu.org ([208.118.235.92]:44106) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1U9Vkm-0000Cy-E1 for bug-gnu-emacs@gnu.org; Sun, 24 Feb 2013 02:12:10 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1U9Vkk-0002LU-Fc for bug-gnu-emacs@gnu.org; Sun, 24 Feb 2013 02:12:08 -0500 Received: from mail-pa0-f47.google.com ([209.85.220.47]:39972) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1U9V9o-00020c-OU for bug-gnu-emacs@gnu.org; Sun, 24 Feb 2013 01:33:56 -0500 Received: by mail-pa0-f47.google.com with SMTP id bj3so1204655pad.20 for ; Sat, 23 Feb 2013 22:33:56 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:date:from:to:subject:message-id:organization:x-mailer :mime-version:content-type:content-transfer-encoding; bh=4lBYP4cSUYyP3GTFDPVwccIzfBphb24lwK/xBZxorI0=; b=E9uXAvmglsqY3iHNHNwrdH97MCujK2xqtIvmcX8BWVcD4FT9jwShQgI12boWoJl/jS RolQVRuFHTygpXa+/FDvdGO9H14/FNdPcL7Cd2hAkw8yRqsRdLC6bdC18GbmncfJ2kN9 iv57E8U2ma4xTdkQqr05Ft4p3ro6RUgj1ZhAkc2rFxni8QqYnHa0srK+larZ41S5OLGh 0mdfT9lGgypML5Eg2OfiVM9u7U1edImVy9rNXdxqjGMaWjhrCK5nFhLteiAZaAxrtpP6 wqRx084tF/g9kk23jOvYP75fiY+rIrXAGgUnI5VYAYo8Z7Qr8bmWL1VoA7oJWfeXDSQe hP7A== X-Received: by 10.68.227.9 with SMTP id rw9mr11754393pbc.185.1361687635934; Sat, 23 Feb 2013 22:33:55 -0800 (PST) Received: from Emacs ([61.149.226.23]) by mx.google.com with ESMTPS id tp2sm8340328pbc.12.2013.02.23.22.33.45 (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Sat, 23 Feb 2013 22:33:54 -0800 (PST) Date: Sun, 24 Feb 2013 14:33:32 +0800 From: Xue Fuqiao Message-Id: <20130224143332.f33f9e158da879bd206e83cc@gmail.com> Organization: The Church of Emacs X-Mailer: Sylpheed 3.2.0 (GTK+ 2.24.13; x86_64-pc-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [fuzzy] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 208.118.235.17 X-Spam-Score: -4.2 (----) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -6.1 (------) I made a minor patch for files.el. The patch does this: 1. Improve the doc string for `break-hardlink-on-save'; 2. Remove an unnecessary `buffer-auto-save-file-name'. *** trunk/lisp/files.el 2013-02-24 06:49:38.358835000 +0800 --- trunk/lisp/files.el.new 2013-02-24 14:23:28.681175258 +0800 *************** See also: `break-hardlink-on-save'." *** 248,259 **** :group 'backup) (defcustom break-hardlink-on-save nil ! "Non-nil means when saving a file that exists under several names ! \(i.e., has multiple hardlinks), break the hardlink associated with ! `buffer-file-name' and write to a new file, so that the other ! instances of the file are not affected by the save. ! If `buffer-file-name' refers to a symlink, do not break the symlink. Unlike `file-precious-flag', `break-hardlink-on-save' is not advisory. For example, if the directory in which a file is being saved is not --- 248,262 ---- :group 'backup) (defcustom break-hardlink-on-save nil ! "This variable affect the relation between hardlink(s) and the file. ! Non-nil means when saving a file that exists under several names ! \(i.e., has multiple hardlinks), break the hardlink associated ! with the variable `buffer-file-name' and write to a new file, so ! that the other instances of the file are not affected by the ! save. ! If the variable`buffer-file-name' refers to a symlink, do not ! break the symlink. Unlike `file-precious-flag', `break-hardlink-on-save' is not advisory. For example, if the directory in which a file is being saved is not *************** non-nil, it is called instead of rereadi *** 5333,5339 **** (let* ((revert-buffer-in-progress-p t) (auto-save-p (and (not ignore-auto) (recent-auto-save-p) - buffer-auto-save-file-name (file-readable-p buffer-auto-save-file-name) (y-or-n-p "Buffer has been auto-saved recently. Revert from auto-save file? "))) --- 5336,5341 ---- *** trunk/lisp/ChangeLog 2013-02-24 06:49:38.358835000 +0800 --- trunk/lisp/ChangeLog.new 2013-02-24 14:27:41.126427073 +0800 *************** *** 1,7 **** 2013-02-23 Peter Kleiweg * progmodes/ps-mode.el (ps-mode-version): Bump to 1.1i. ! (ps-mode-octal-region): Use string-make-unibyte. 2013-02-23 Glenn Morris --- 1,12 ---- + 2013-02-24 Xue Fuqiao + + * files.el (break-hardlink-on-save): Doc fix. + (revert-buffer): Remove the unnecessary `buffer-auto-save-file-name'. + 2013-02-23 Peter Kleiweg * progmodes/ps-mode.el (ps-mode-version): Bump to 1.1i. ! (ps-mode-octal-region): Use `string-make-unibyte'. 2013-02-23 Glenn Morris -- Best regards, Xue Fuqiao. http://www.emacswiki.org/emacs/XueFuqiao From unknown Sun Jun 22 17:15:26 2025 X-Loop: help-debbugs@gnu.org Subject: bug#13801: [PATCH] Trivial fix for files.el Resent-From: Eli Zaretskii Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 24 Feb 2013 15:10:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 13801 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch To: Xue Fuqiao Cc: 13801@debbugs.gnu.org Reply-To: Eli Zaretskii Received: via spool by 13801-submit@debbugs.gnu.org id=B13801.136171855122021 (code B ref 13801); Sun, 24 Feb 2013 15:10:01 +0000 Received: (at 13801) by debbugs.gnu.org; 24 Feb 2013 15:09:11 +0000 Received: from localhost ([127.0.0.1]:47659 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1U9dCQ-0005j8-IX for submit@debbugs.gnu.org; Sun, 24 Feb 2013 10:09:10 -0500 Received: from mtaout22.012.net.il ([80.179.55.172]:61504) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1U9dCP-0005j1-KM for 13801@debbugs.gnu.org; Sun, 24 Feb 2013 10:09:10 -0500 Received: from conversion-daemon.a-mtaout22.012.net.il by a-mtaout22.012.net.il (HyperSendmail v2007.08) id <0MIQ00E00CLWL900@a-mtaout22.012.net.il> for 13801@debbugs.gnu.org; Sun, 24 Feb 2013 17:06:49 +0200 (IST) Received: from HOME-C4E4A596F7 ([87.69.4.28]) by a-mtaout22.012.net.il (HyperSendmail v2007.08) with ESMTPA id <0MIQ00E01CNCH130@a-mtaout22.012.net.il>; Sun, 24 Feb 2013 17:06:49 +0200 (IST) Date: Sun, 24 Feb 2013 17:06:39 +0200 From: Eli Zaretskii In-reply-to: <20130224143332.f33f9e158da879bd206e83cc@gmail.com> X-012-Sender: halo1@inter.net.il Message-id: <83mwutkayo.fsf@gnu.org> References: <20130224143332.f33f9e158da879bd206e83cc@gmail.com> X-Spam-Score: 0.7 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -1.2 (-) > Date: Sun, 24 Feb 2013 14:33:32 +0800 > From: Xue Fuqiao > > *** trunk/lisp/files.el 2013-02-24 06:49:38.358835000 +0800 > --- trunk/lisp/files.el.new 2013-02-24 14:23:28.681175258 +0800 > *************** See also: `break-hardlink-on-save'." > *** 248,259 **** > :group 'backup) > > (defcustom break-hardlink-on-save nil > ! "Non-nil means when saving a file that exists under several names > ! \(i.e., has multiple hardlinks), break the hardlink associated with > ! `buffer-file-name' and write to a new file, so that the other > ! instances of the file are not affected by the save. > > ! If `buffer-file-name' refers to a symlink, do not break the symlink. > > Unlike `file-precious-flag', `break-hardlink-on-save' is not advisory. > For example, if the directory in which a file is being saved is not > --- 248,262 ---- > :group 'backup) > > (defcustom break-hardlink-on-save nil > ! "This variable affect the relation between hardlink(s) and the file. > ! Non-nil means when saving a file that exists under several names > ! \(i.e., has multiple hardlinks), break the hardlink associated > ! with the variable `buffer-file-name' and write to a new file, so > ! that the other instances of the file are not affected by the > ! save. The first line of the doc string should concisely say what the option does. The old doc string did it, albeit not perfectly; the one you suggest does not. From unknown Sun Jun 22 17:15:26 2025 X-Loop: help-debbugs@gnu.org Subject: bug#13801: [PATCH] Trivial fix for files.el Resent-From: "Drew Adams" Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 24 Feb 2013 17:50:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 13801 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch To: "'Eli Zaretskii'" , "'Xue Fuqiao'" Cc: 13801@debbugs.gnu.org Received: via spool by 13801-submit@debbugs.gnu.org id=B13801.13617281744076 (code B ref 13801); Sun, 24 Feb 2013 17:50:02 +0000 Received: (at 13801) by debbugs.gnu.org; 24 Feb 2013 17:49:34 +0000 Received: from localhost ([127.0.0.1]:47828 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1U9fhd-00013g-LM for submit@debbugs.gnu.org; Sun, 24 Feb 2013 12:49:33 -0500 Received: from aserp1040.oracle.com ([141.146.126.69]:21985) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1U9fha-00013Y-5m for 13801@debbugs.gnu.org; Sun, 24 Feb 2013 12:49:31 -0500 Received: from ucsinet22.oracle.com (ucsinet22.oracle.com [156.151.31.94]) by aserp1040.oracle.com (Sentrion-MTA-4.3.1/Sentrion-MTA-4.3.1) with ESMTP id r1OHlrrD000471 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Sun, 24 Feb 2013 17:47:54 GMT Received: from acsmt356.oracle.com (acsmt356.oracle.com [141.146.40.156]) by ucsinet22.oracle.com (8.14.4+Sun/8.14.4) with ESMTP id r1OHlqeC022518 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Sun, 24 Feb 2013 17:47:53 GMT Received: from abhmt111.oracle.com (abhmt111.oracle.com [141.146.116.63]) by acsmt356.oracle.com (8.12.11.20060308/8.12.11) with ESMTP id r1OHlqHO024158; Sun, 24 Feb 2013 11:47:52 -0600 Received: from dradamslap1 (/71.202.147.44) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Sun, 24 Feb 2013 09:47:52 -0800 From: "Drew Adams" References: <20130224143332.f33f9e158da879bd206e83cc@gmail.com> <83mwutkayo.fsf@gnu.org> Date: Sun, 24 Feb 2013 09:47:44 -0800 Message-ID: <6EA8FD3B20FB44C289A386DEA3E477D9@us.oracle.com> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Mailer: Microsoft Office Outlook 11 In-Reply-To: <83mwutkayo.fsf@gnu.org> Thread-Index: Ac4SoNDzA49yIz9JTF+MZNzrH1iKzAAEn0eA X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.6157 X-Source-IP: ucsinet22.oracle.com [156.151.31.94] X-Spam-Score: -2.2 (--) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -3.5 (---) > The first line of the doc string should concisely say what > the option does. Correct. Including, if possible, what a nil or non-nil value does, if the option is Boolean. And the first line should (must) be a full sentence. > The old doc string did it, albeit not perfectly; Incorrect. The first line did not do that at all. At all. > the one you suggest does not. Correct. My guess is that it was an attempt to provide a short full sentence (good), but it does not say what the option does (not good). What is important in both the old and new doc strings, and can serve as the first line, is that the option does this (77 chars): "Non-nil means break a hard link for the visited file and write to a new file." If you feel that 77 chars is too much, you can drop "a" before "hard link" or "the" before "visited file". The rest of the doc string can clarify things further (e.g., mentioning `buffer-file-name'). Whatever the wording chosen, the point is that non-nil means Emacs writes a new file, bypassing any hard link for `buffer-file-name'. In fact, I'm not sure about "break" here. Is the effect that the hard link no longer exists, or simply that it is ignored by Emacs when saving? Depending on the answer, the doc might need to be tweaked a little more. The old first line was not even a complete sentence. And the old first sentence was four lines! And unless I'm mistaken, the old first sentence was incorrect or at least misleading regarding the condition where the option applies: "has multiple hardlinks". I think the correct criterion is simply having a hard link for the visited file (`buffer-file-name'), regardless of whether there are any other hard links, i.e., not necessarily multiple such. It is not easy to write a short summary sentence, especially when English is not your maternal language. This is a welcome initiative from Fuqiao. He clearly takes an interest in the doc (as do Eli and Drew), and that is a fairly rare resource. Thank you. From unknown Sun Jun 22 17:15:26 2025 X-Loop: help-debbugs@gnu.org Subject: bug#13801: [PATCH] Trivial fix for files.el Resent-From: Stephen Berman Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 24 Feb 2013 21:50:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 13801 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch To: "Drew Adams" Cc: 'Xue Fuqiao' , 'Eli Zaretskii' , 13801@debbugs.gnu.org Received: via spool by 13801-submit@debbugs.gnu.org id=B13801.136174257630250 (code B ref 13801); Sun, 24 Feb 2013 21:50:01 +0000 Received: (at 13801) by debbugs.gnu.org; 24 Feb 2013 21:49:36 +0000 Received: from localhost ([127.0.0.1]:48145 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1U9jRv-0007rq-Tn for submit@debbugs.gnu.org; Sun, 24 Feb 2013 16:49:36 -0500 Received: from mout.gmx.net ([212.227.15.18]:56859) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1U9jRr-0007rh-I5 for 13801@debbugs.gnu.org; Sun, 24 Feb 2013 16:49:33 -0500 Received: from mailout-de.gmx.net ([10.1.76.32]) by mrigmx.server.lan (mrigmx001) with ESMTP (Nemesis) id 0MPb5D-1UEQMA2mUT-004h2P for <13801@debbugs.gnu.org>; Sun, 24 Feb 2013 22:45:43 +0100 Received: (qmail invoked by alias); 24 Feb 2013 21:45:43 -0000 Received: from i59F550B9.versanet.de (EHLO rosalinde.fritz.box) [89.245.80.185] by mail.gmx.net (mp032) with SMTP; 24 Feb 2013 22:45:43 +0100 X-Authenticated: #20778731 X-Provags-ID: V01U2FsdGVkX1/fEF9Z0uLfLMDcASNmomD1rdZkNCLacjY27mCvh2 2NRvik5GIAwWY3 From: Stephen Berman References: <20130224143332.f33f9e158da879bd206e83cc@gmail.com> <83mwutkayo.fsf@gnu.org> <6EA8FD3B20FB44C289A386DEA3E477D9@us.oracle.com> Date: Sun, 24 Feb 2013 22:45:41 +0100 In-Reply-To: <6EA8FD3B20FB44C289A386DEA3E477D9@us.oracle.com> (Drew Adams's message of "Sun, 24 Feb 2013 09:47:44 -0800") Message-ID: <87wqtx5qt6.fsf@rosalinde.fritz.box> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Y-GMX-Trusted: 0 X-Spam-Score: 0.1 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.6 (--) On Sun, 24 Feb 2013 09:47:44 -0800 "Drew Adams" wrote: >> The first line of the doc string should concisely say what >> the option does. > > Correct. > > Including, if possible, what a nil or non-nil value does, if the option is > Boolean. And the first line should (must) be a full sentence. > >> The old doc string did it, albeit not perfectly; > > Incorrect. The first line did not do that at all. At all. > >> the one you suggest does not. > > Correct. My guess is that it was an attempt to provide a short full sentence > (good), but it does not say what the option does (not good). > > What is important in both the old and new doc strings, and can serve as the > first line, is that the option does this (77 chars): > > "Non-nil means break a hard link for the visited file and write to a new file." To keep it under 68 characters (as per (elisp) Documentation Tips), how about: Non-nil means write visited file to a new file, breaking hard links. Steve Berman From unknown Sun Jun 22 17:15:26 2025 X-Loop: help-debbugs@gnu.org Subject: bug#13801: [PATCH] Trivial fix for files.el Resent-From: "Drew Adams" Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 24 Feb 2013 22:29:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 13801 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch To: "'Stephen Berman'" Cc: 'Xue Fuqiao' , 'Eli Zaretskii' , 13801@debbugs.gnu.org Received: via spool by 13801-submit@debbugs.gnu.org id=B13801.13617449361275 (code B ref 13801); Sun, 24 Feb 2013 22:29:01 +0000 Received: (at 13801) by debbugs.gnu.org; 24 Feb 2013 22:28:56 +0000 Received: from localhost ([127.0.0.1]:48202 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1U9k3z-0000KV-RG for submit@debbugs.gnu.org; Sun, 24 Feb 2013 17:28:56 -0500 Received: from aserp1040.oracle.com ([141.146.126.69]:21994) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1U9k3x-0000KO-RF for 13801@debbugs.gnu.org; Sun, 24 Feb 2013 17:28:54 -0500 Received: from ucsinet21.oracle.com (ucsinet21.oracle.com [156.151.31.93]) by aserp1040.oracle.com (Sentrion-MTA-4.3.1/Sentrion-MTA-4.3.1) with ESMTP id r1OMRGE2019806 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Sun, 24 Feb 2013 22:27:16 GMT Received: from acsmt356.oracle.com (acsmt356.oracle.com [141.146.40.156]) by ucsinet21.oracle.com (8.14.4+Sun/8.14.4) with ESMTP id r1OMRF1d018784 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Sun, 24 Feb 2013 22:27:15 GMT Received: from abhmt114.oracle.com (abhmt114.oracle.com [141.146.116.66]) by acsmt356.oracle.com (8.12.11.20060308/8.12.11) with ESMTP id r1OMRESv027769; Sun, 24 Feb 2013 16:27:14 -0600 Received: from dradamslap1 (/71.202.147.44) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Sun, 24 Feb 2013 14:27:14 -0800 From: "Drew Adams" References: <20130224143332.f33f9e158da879bd206e83cc@gmail.com><83mwutkayo.fsf@gnu.org><6EA8FD3B20FB44C289A386DEA3E477D9@us.oracle.com> <87wqtx5qt6.fsf@rosalinde.fritz.box> Date: Sun, 24 Feb 2013 14:27:06 -0800 Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Mailer: Microsoft Office Outlook 11 In-Reply-To: <87wqtx5qt6.fsf@rosalinde.fritz.box> Thread-Index: Ac4S23uIXTQdl6KKQaCpFR5kC1FtnQAAXTwg X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.6157 X-Source-IP: ucsinet21.oracle.com [156.151.31.93] X-Spam-Score: -2.2 (--) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -3.0 (---) > > "Non-nil means break a hard link for the visited file and > write to a new file." > > To keep it under 68 characters (as per (elisp) Documentation > Tips), how about: > > Non-nil means write visited file to a new file, breaking hard links. OK by me. (I was thinking the guideline limit is more than 68.) But that text suggests that a new file is always used. Using "any hard link" or "a hard link" is a bit better, suggesting that the new file thing is conditional on there being a hard link. Maybe this (66 chars)? Non-nil means write new file if `buffer-file-name' is hard-linked. From unknown Sun Jun 22 17:15:26 2025 X-Loop: help-debbugs@gnu.org Subject: bug#13801: [PATCH] Trivial fix for files.el Resent-From: Xue Fuqiao Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 24 Feb 2013 22:50:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 13801 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch To: "Drew Adams" Cc: 'Eli Zaretskii' , 'Stephen Berman' , 13801@debbugs.gnu.org Received: via spool by 13801-submit@debbugs.gnu.org id=B13801.13617461503895 (code B ref 13801); Sun, 24 Feb 2013 22:50:02 +0000 Received: (at 13801) by debbugs.gnu.org; 24 Feb 2013 22:49:10 +0000 Received: from localhost ([127.0.0.1]:48261 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1U9kNa-00010m-2y for submit@debbugs.gnu.org; Sun, 24 Feb 2013 17:49:10 -0500 Received: from mail-da0-f49.google.com ([209.85.210.49]:65446) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1U9kNX-00010e-TG for 13801@debbugs.gnu.org; Sun, 24 Feb 2013 17:49:08 -0500 Received: by mail-da0-f49.google.com with SMTP id t11so235690daj.8 for <13801@debbugs.gnu.org>; Sun, 24 Feb 2013 14:47:31 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:date:from:to:cc:subject:message-id:in-reply-to :references:organization:x-mailer:mime-version:content-type :content-transfer-encoding; bh=qu5FRx8+tT6BPH7NppPpJcxZQYrsMnKfI40rWTtJq4U=; b=pCSjBfG7EhL+51b9wd7ZNpW18IojJiUpacFNo0o0nHAiScd56T160T05wkEPmgpvAG Mn4ujZTL7vS+/E0l7UDjsww45H3Lcx/gYX8GcUgn4T+/2xqWjPnz0BcczK9ix2QstLxu Q7KwOB4egfKhDfqwAchNmKoJADIy1Nk+2doBwlqAXw5qm9+wa5ZCeE8qtBfmdOKtQkO+ TUVrSxqRHVgTbxlgQC7XxjBl1cwAc3T6nanGay+feX/caxTcJ9PDMSyXwC/PoY4R8OVO PuxsvarVBayf/GL9mnXVhrfmE9ghghC7ZgQLNXGqp6EmkrZojHKnqhYellKAyl9S/oGI IOdw== X-Received: by 10.66.216.161 with SMTP id or1mr15809917pac.120.1361746051484; Sun, 24 Feb 2013 14:47:31 -0800 (PST) Received: from Emacs ([61.149.225.108]) by mx.google.com with ESMTPS id o5sm11327141pay.5.2013.02.24.14.47.28 (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Sun, 24 Feb 2013 14:47:30 -0800 (PST) Date: Mon, 25 Feb 2013 06:47:26 +0800 From: Xue Fuqiao Message-Id: <20130225064726.055f56d71d382b127005836d@gmail.com> In-Reply-To: References: <20130224143332.f33f9e158da879bd206e83cc@gmail.com> <83mwutkayo.fsf@gnu.org> <6EA8FD3B20FB44C289A386DEA3E477D9@us.oracle.com> <87wqtx5qt6.fsf@rosalinde.fritz.box> Organization: The Church of Emacs X-Mailer: Sylpheed 3.2.0 (GTK+ 2.24.13; x86_64-pc-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Spam-Score: 0.1 (/) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.6 (--) On Sun, 24 Feb 2013 14:27:06 -0800 "Drew Adams" wrote: > > > "Non-nil means break a hard link for the visited file and > > write to a new file." > > To keep it under 68 characters (as per (elisp) Documentation > > Tips), how about: > > Non-nil means write visited file to a new file, breaking hard links. > OK by me. (I was thinking the guideline limit is more than 68.) > But that text suggests that a new file is always used. Using "any hard link" or > "a hard link" is a bit better, suggesting that the new file thing is conditional > on there being a hard link. > Maybe this (66 chars)? > Non-nil means write new file if `buffer-file-name' is hard-linked. I think there are three problems (to me) about this version: 1. "write new file" is confusing. I don't know what kind of thing will be write to which file; 2. `buffer-file-name' has both a function cell and a value cell, a little confusing; 2. `buffer-file-name' is a string (or returns a string), not a file, so the file cannot be hard-linked. But I can't give a better version, sorry. -- Best regards, Xue Fuqiao. http://www.emacswiki.org/emacs/XueFuqiao From unknown Sun Jun 22 17:15:26 2025 MIME-Version: 1.0 X-Mailer: MIME-tools 5.503 (Entity 5.503) X-Loop: help-debbugs@gnu.org From: help-debbugs@gnu.org (GNU bug Tracking System) To: Xue Fuqiao Subject: bug#13801: closed (Re: bug#13801: [PATCH] Trivial fix for files.el) Message-ID: References: <87sitr344b.fsf@gmail.com> <20130224143332.f33f9e158da879bd206e83cc@gmail.com> X-Gnu-PR-Message: they-closed 13801 X-Gnu-PR-Package: emacs X-Gnu-PR-Keywords: patch Reply-To: 13801@debbugs.gnu.org Date: Tue, 17 Dec 2013 15:11:03 +0000 Content-Type: multipart/mixed; boundary="----------=_1387293063-17949-1" This is a multi-part message in MIME format... ------------=_1387293063-17949-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Your bug report #13801: [PATCH] Trivial fix for files.el 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 13801@debbugs.gnu.org. --=20 13801: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=3D13801 GNU Bug Tracking System Contact help-debbugs@gnu.org with problems ------------=_1387293063-17949-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at 13801-done) by debbugs.gnu.org; 17 Dec 2013 15:10:35 +0000 Received: from localhost ([127.0.0.1]:55898 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1VswI6-0004eX-4t for submit@debbugs.gnu.org; Tue, 17 Dec 2013 10:10:35 -0500 Received: from mail-pa0-f54.google.com ([209.85.220.54]:53095) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1VswI3-0004eM-HV for 13801-done@debbugs.gnu.org; Tue, 17 Dec 2013 10:10:31 -0500 Received: by mail-pa0-f54.google.com with SMTP id rd3so4559647pab.41 for <13801-done@debbugs.gnu.org>; Tue, 17 Dec 2013 07:10:30 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version:content-type; bh=cCrwGCwZlahaK7ErEsnFx/5SbwwzbOnLVtpro+TKvgw=; b=Zi2VF+Pze6YLBwmQ8g/8NPJFwidh8wiSDvPrHsyRDh9v7LU12mdHIDJSnCaGmY9hdH zKZcumuotWMYpiEwhxsw4QS1U/mleqigqRDhTiAgvdBGzGaKbeNIuxtramswtWeKaGN0 5/yB6hk8p5/+tP8niQ9tNwpb1BsAwzG+lCkdcCmA+6E0bIt0L6wYL3/KWcMGbbeau+0n xvyud6iO4WznClT+c/8UU11o7QrLmwcTA0Rsq/wnUm/tuHvXvALolmchieq/X/OeCiNZ T0tjcWbz2f+2wMT2dYnJPS6gsou0f9L2ox3R1bH+ElRHp95AVJxARkJtlZXvuY6vvYk5 tiTA== X-Received: by 10.68.230.228 with SMTP id tb4mr460427pbc.108.1387293030682; Tue, 17 Dec 2013 07:10:30 -0800 (PST) Received: from tsparkle ([155.69.2.31]) by mx.google.com with ESMTPSA id m2sm34552746pbn.19.2013.12.17.07.10.28 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 17 Dec 2013 07:10:29 -0800 (PST) From: Chong Yidong To: Xue Fuqiao Subject: Re: bug#13801: [PATCH] Trivial fix for files.el References: <20130224143332.f33f9e158da879bd206e83cc@gmail.com> Date: Tue, 17 Dec 2013 23:10:28 +0800 In-Reply-To: <20130224143332.f33f9e158da879bd206e83cc@gmail.com> (Xue Fuqiao's message of "Sun, 24 Feb 2013 14:33:32 +0800") Message-ID: <87sitr344b.fsf@gmail.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 13801-done Cc: 13801-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 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.7 (/) Xue Fuqiao writes: > I made a minor patch for files.el. The patch does this: > > 1. Improve the doc string for `break-hardlink-on-save'; Thanks, I committed a slightly different fix. > 2. Remove an unnecessary `buffer-auto-save-file-name'. > > - buffer-auto-save-file-name > (file-readable-p buffer-auto-save-file-name) This is not unnecessary. If buffer-auto-save-file-name is nil, the next line would signal an error, which is undesireable. ------------=_1387293063-17949-1 Content-Type: message/rfc822 Content-Disposition: inline Content-Transfer-Encoding: 7bit Received: (at submit) by debbugs.gnu.org; 24 Feb 2013 07:13:48 +0000 Received: from localhost ([127.0.0.1]:46465 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1U9VmN-0001yj-K8 for submit@debbugs.gnu.org; Sun, 24 Feb 2013 02:13:48 -0500 Received: from eggs.gnu.org ([208.118.235.92]:60988) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1U9VmK-0001yb-92 for submit@debbugs.gnu.org; Sun, 24 Feb 2013 02:13:45 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1U9Vko-0002Mj-Ic for submit@debbugs.gnu.org; Sun, 24 Feb 2013 02:12:12 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-102.6 required=5.0 tests=BAYES_00,FREEMAIL_FROM, RCVD_IN_DNSWL_LOW, T_DKIM_INVALID, USER_IN_WHITELIST autolearn=unavailable version=3.3.2 Received: from lists.gnu.org ([208.118.235.17]:54835) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1U9Vko-0002MT-Ez for submit@debbugs.gnu.org; Sun, 24 Feb 2013 02:12:10 -0500 Received: from eggs.gnu.org ([208.118.235.92]:44106) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1U9Vkm-0000Cy-E1 for bug-gnu-emacs@gnu.org; Sun, 24 Feb 2013 02:12:10 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1U9Vkk-0002LU-Fc for bug-gnu-emacs@gnu.org; Sun, 24 Feb 2013 02:12:08 -0500 Received: from mail-pa0-f47.google.com ([209.85.220.47]:39972) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1U9V9o-00020c-OU for bug-gnu-emacs@gnu.org; Sun, 24 Feb 2013 01:33:56 -0500 Received: by mail-pa0-f47.google.com with SMTP id bj3so1204655pad.20 for ; Sat, 23 Feb 2013 22:33:56 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:date:from:to:subject:message-id:organization:x-mailer :mime-version:content-type:content-transfer-encoding; bh=4lBYP4cSUYyP3GTFDPVwccIzfBphb24lwK/xBZxorI0=; b=E9uXAvmglsqY3iHNHNwrdH97MCujK2xqtIvmcX8BWVcD4FT9jwShQgI12boWoJl/jS RolQVRuFHTygpXa+/FDvdGO9H14/FNdPcL7Cd2hAkw8yRqsRdLC6bdC18GbmncfJ2kN9 iv57E8U2ma4xTdkQqr05Ft4p3ro6RUgj1ZhAkc2rFxni8QqYnHa0srK+larZ41S5OLGh 0mdfT9lGgypML5Eg2OfiVM9u7U1edImVy9rNXdxqjGMaWjhrCK5nFhLteiAZaAxrtpP6 wqRx084tF/g9kk23jOvYP75fiY+rIrXAGgUnI5VYAYo8Z7Qr8bmWL1VoA7oJWfeXDSQe hP7A== X-Received: by 10.68.227.9 with SMTP id rw9mr11754393pbc.185.1361687635934; Sat, 23 Feb 2013 22:33:55 -0800 (PST) Received: from Emacs ([61.149.226.23]) by mx.google.com with ESMTPS id tp2sm8340328pbc.12.2013.02.23.22.33.45 (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Sat, 23 Feb 2013 22:33:54 -0800 (PST) Date: Sun, 24 Feb 2013 14:33:32 +0800 From: Xue Fuqiao To: bug-gnu-emacs@gnu.org Subject: [PATCH] Trivial fix for files.el Message-Id: <20130224143332.f33f9e158da879bd206e83cc@gmail.com> Organization: The Church of Emacs X-Mailer: Sylpheed 3.2.0 (GTK+ 2.24.13; x86_64-pc-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [fuzzy] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 208.118.235.17 X-Spam-Score: -4.2 (----) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -6.1 (------) I made a minor patch for files.el. The patch does this: 1. Improve the doc string for `break-hardlink-on-save'; 2. Remove an unnecessary `buffer-auto-save-file-name'. *** trunk/lisp/files.el 2013-02-24 06:49:38.358835000 +0800 --- trunk/lisp/files.el.new 2013-02-24 14:23:28.681175258 +0800 *************** See also: `break-hardlink-on-save'." *** 248,259 **** :group 'backup) (defcustom break-hardlink-on-save nil ! "Non-nil means when saving a file that exists under several names ! \(i.e., has multiple hardlinks), break the hardlink associated with ! `buffer-file-name' and write to a new file, so that the other ! instances of the file are not affected by the save. ! If `buffer-file-name' refers to a symlink, do not break the symlink. Unlike `file-precious-flag', `break-hardlink-on-save' is not advisory. For example, if the directory in which a file is being saved is not --- 248,262 ---- :group 'backup) (defcustom break-hardlink-on-save nil ! "This variable affect the relation between hardlink(s) and the file. ! Non-nil means when saving a file that exists under several names ! \(i.e., has multiple hardlinks), break the hardlink associated ! with the variable `buffer-file-name' and write to a new file, so ! that the other instances of the file are not affected by the ! save. ! If the variable`buffer-file-name' refers to a symlink, do not ! break the symlink. Unlike `file-precious-flag', `break-hardlink-on-save' is not advisory. For example, if the directory in which a file is being saved is not *************** non-nil, it is called instead of rereadi *** 5333,5339 **** (let* ((revert-buffer-in-progress-p t) (auto-save-p (and (not ignore-auto) (recent-auto-save-p) - buffer-auto-save-file-name (file-readable-p buffer-auto-save-file-name) (y-or-n-p "Buffer has been auto-saved recently. Revert from auto-save file? "))) --- 5336,5341 ---- *** trunk/lisp/ChangeLog 2013-02-24 06:49:38.358835000 +0800 --- trunk/lisp/ChangeLog.new 2013-02-24 14:27:41.126427073 +0800 *************** *** 1,7 **** 2013-02-23 Peter Kleiweg * progmodes/ps-mode.el (ps-mode-version): Bump to 1.1i. ! (ps-mode-octal-region): Use string-make-unibyte. 2013-02-23 Glenn Morris --- 1,12 ---- + 2013-02-24 Xue Fuqiao + + * files.el (break-hardlink-on-save): Doc fix. + (revert-buffer): Remove the unnecessary `buffer-auto-save-file-name'. + 2013-02-23 Peter Kleiweg * progmodes/ps-mode.el (ps-mode-version): Bump to 1.1i. ! (ps-mode-octal-region): Use `string-make-unibyte'. 2013-02-23 Glenn Morris -- Best regards, Xue Fuqiao. http://www.emacswiki.org/emacs/XueFuqiao ------------=_1387293063-17949-1--