From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: Juri Linkov Newsgroups: gmane.emacs.devel Subject: Re: Documentation for custom-file - is not (load custom-file) needed? Date: Wed, 08 Dec 2004 15:27:32 +0200 Organization: JURTA Message-ID: <87u0qwc43f.fsf@jurta.org> References: <075b01c4d9a4$52799460$0200a8c0@sedrcw11488> <00bb01c4daee$5eb81350$0200a8c0@sedrcw11488> <200412051733.iB5HXIX13206@raven.dms.auburn.edu> <000001c4db1a$8d3770f0$0200a8c0@sedrcw11488> <200412060046.iB60kZj15003@raven.dms.auburn.edu> <003e01c4db31$e45a2550$0200a8c0@sedrcw11488> <200412060402.iB6421q15173@raven.dms.auburn.edu> <200412070539.iB75dV924747@raven.dms.auburn.edu> <03be01c4dcbf$139bfa30$0200a8c0@sedrcw11488> <87is7dienm.fsf@jurta.org> NNTP-Posting-Host: deer.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1102513172 17053 80.91.229.6 (8 Dec 2004 13:39:32 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Wed, 8 Dec 2004 13:39:32 +0000 (UTC) Cc: teirllm@dms.auburn.edu, emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Wed Dec 08 14:39:18 2004 Return-path: Original-Received: from lists.gnu.org ([199.232.76.165]) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1Cc22H-0007AQ-00 for ; Wed, 08 Dec 2004 14:39:18 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.33) id 1Cc2C8-00019v-83 for ged-emacs-devel@m.gmane.org; Wed, 08 Dec 2004 08:49:28 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.33) id 1Cc2Bh-0000zS-Jw for emacs-devel@gnu.org; Wed, 08 Dec 2004 08:49:01 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.33) id 1Cc2Bg-0000yd-0Z for emacs-devel@gnu.org; Wed, 08 Dec 2004 08:49:00 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.33) id 1Cc2Bf-0000yH-Rb for emacs-devel@gnu.org; Wed, 08 Dec 2004 08:48:59 -0500 Original-Received: from [194.126.101.111] (helo=MXR-3.estpak.ee) by monty-python.gnu.org with esmtp (Exim 4.34) id 1Cc21R-0001Tt-Pv for emacs-devel@gnu.org; Wed, 08 Dec 2004 08:38:26 -0500 Original-Received: from jurta.org.jurta.org (80-235-39-106-dsl.mus.estpak.ee [80.235.39.106]) by MXR-3.estpak.ee (Postfix) with ESMTP id 89D0ACF20A; Wed, 8 Dec 2004 15:38:19 +0200 (EET) Original-To: "Lennart Borgman" In-Reply-To: <87is7dienm.fsf@jurta.org> (Juri Linkov's message of "Wed, 08 Dec 2004 06:42:53 +0200") User-Agent: Gnus/5.110002 (No Gnus v0.2) Emacs/21.3.50 (gnu/linux) X-Virus-Scanned: by amavisd-new-20030616-p10 (Debian) at neti.ee X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: main.gmane.org gmane.emacs.devel:30860 X-Report-Spam: http://spam.gmane.org/gmane.emacs.devel:30860 I wrote: > It's too late to make any changes in custom-file (changing its type, > etc.) since users might already rely on its current state. But maybe it is safe to change the type of custom-file from defcustom to defvar. I am only concerned about backward compatibility. What happens if some users already have customized `custom-file' in `custom-set-variables' and it will be removed from this list? Perhaps, nothing bad. Moreover, the situation where `custom-file' in `custom-set-variables' points to some file other than the file where `custom-set-variables' is located, is invalid. It will cause duplication of `custom-set-variables' list when Emacs saves customized variables next time. So, not adding `custom-file' to the set of variables in `custom-set-variables' is the right thing. `custom-file' should be purely an internal variable (which is achieved with the previous patch). However, there is one situation when users have to deal with the `custom-file' variable. When the user moves `custom-set-variables' to a new location in another file, it's needed to tell Emacs about this location, so the next invocation of `Custom-save' could write customization to the new place. To inform users about that, the next 3 lines could be added to the comments of `custom-set-variables': (custom-set-variables ;; custom-set-variables was added by Custom. ;; If you edit it by hand, you could mess it up, so be careful. ;; Your init file should contain only one such instance. ;; If there is more than one, they won't work right. + ;; When you move it to another init file, to tell Emacs about + ;; its new location for the current Emacs session, type C-x C-e + ;; at the end of this line: (setq custom-file buffer-file-name) + ;; For further Emacs sessions just put in your init file + ;; (load "custom-file.el"). There is no need to set `custom-file' + ;; explicitly in your init files since Emacs can automatically set + ;; it to the file name where your customizations were loaded from. ... -- Juri Linkov http://www.jurta.org/emacs/