From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Pedro Andres Aranda Gutierrez Newsgroups: gmane.emacs.devel Subject: Re: Default custom file was: Re: Propose to add setup-wizard.el to ELPA Date: Tue, 4 Jan 2022 07:13:59 +0100 Message-ID: References: <740A136F-8710-4F4C-BFC1-A3DB418447F4@gmail.com> <87zgoc7u6k.fsf@gmail.com> Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="00000000000092204705d4bb8c9e" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="32345"; mail-complaints-to="usenet@ciao.gmane.io" Cc: emacs-devel To: Robert Pluim Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Tue Jan 04 07:19:55 2022 Return-path: Envelope-to: ged-emacs-devel@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 1n4dAo-0008GP-TC for ged-emacs-devel@m.gmane-mx.org; Tue, 04 Jan 2022 07:19:55 +0100 Original-Received: from localhost ([::1]:59232 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1n4dAn-0005jw-GC for ged-emacs-devel@m.gmane-mx.org; Tue, 04 Jan 2022 01:19:53 -0500 Original-Received: from eggs.gnu.org ([209.51.188.92]:56992) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n4d5d-00044m-0t for emacs-devel@gnu.org; Tue, 04 Jan 2022 01:14:33 -0500 Original-Received: from [2a00:1450:4864:20::52d] (port=33472 helo=mail-ed1-x52d.google.com) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1n4d5Y-00048P-3U for emacs-devel@gnu.org; Tue, 04 Jan 2022 01:14:32 -0500 Original-Received: by mail-ed1-x52d.google.com with SMTP id m21so145444038edc.0 for ; Mon, 03 Jan 2022 22:14:27 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=KOlruHVTQLwWa51s1xGs1VtEBRnI2QyUneSqkt27aTo=; b=aghwOJbHNu77Tx55dO7xExgjSA5QsY6sV/psNp4HVXJLG8IDBCE7xq9AU/vrK8Vvhp f53QYuwfm43l/Wdj2D7kKxMgkbJLkuYv+dysYBNPHVj8SCp2yelkVau9/3KLTDyUL5et /7SJ6fNtisXv97KDCGfeKBp1HBS1JdEV9bAwKYEIwhIGwMTzKItU0XoYGSqTm8DDau4L NF86puI/tN4uUk9uf6V1gQ9ewlnRp0UQ2+kxEjqIewMv2zX4Id9qHzhBdjYZwIvnkkyk +MHBvJ2d2sQ+G9sRKT35/80DDPXN8iyh9oehywEEitz9gQ/s2ihA9tlBKFVGWAwY9EuJ 0pCQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=KOlruHVTQLwWa51s1xGs1VtEBRnI2QyUneSqkt27aTo=; b=q0kX6+DkT13SeUci3sbrNDPPBeGnwmdK8rejDyie2ccRAOFwqV0gH+UxleuDnfiRl5 XCvwgL6PKAo0C992koi/xf/0UgcEyTpKmaDd7bK/FEa/bXt6EnfGkCMgxRCka2IwUxfU nUOHloT0QsPNzlZbU61632x6PYxjOYalStSsYT34DX0rZs4eD2c9glr59MAON9mrSIbz XBnkVI3LJb0h2sEIb1QNajSE6nEsom7/D8Sp94eOb6dv9J3IneNdGtqW0FPJW8g4uZDB Tozhb8YkH5gqAa77dfOY9L2pVpFTz1eTtwRRyzS9rR7BS6Y3vjMDlg/FRPZbbFfgf4mA CtOw== X-Gm-Message-State: AOAM533ctu5nSfiCHeogL0EMdPFEffnEXu2/V7a/g5oSTKNE8YrPUYQF /dStB8fcg22C/OtVGIsVSAf/aQvw8tFR7EHBxwo= X-Google-Smtp-Source: ABdhPJwSzOygipLUDkJz6OZXIzQJ24GSCPFBDAdB0qWOesg8s/yEjA4QyYtkuKkt6HsAihxCtvQfHTr7xotPsfB6g9A= X-Received: by 2002:a17:906:f02:: with SMTP id z2mr28428091eji.499.1641276865911; Mon, 03 Jan 2022 22:14:25 -0800 (PST) In-Reply-To: <87zgoc7u6k.fsf@gmail.com> X-Host-Lookup-Failed: Reverse DNS lookup failed for 2a00:1450:4864:20::52d (failed) Received-SPF: pass client-ip=2a00:1450:4864:20::52d; envelope-from=paaguti@gmail.com; helo=mail-ed1-x52d.google.com X-Spam_score_int: 6 X-Spam_score: 0.6 X-Spam_bar: / X-Spam_report: (0.6 / 5.0 requ) DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_NONE=-0.0001, RDNS_NONE=0.793, SPF_HELO_NONE=0.001, T_SPF_TEMPERROR=0.01 autolearn=no autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:284127 Archived-At: --00000000000092204705d4bb8c9e Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Hi, I know that dropping .emacs altogether might be radical. I was trying to tease in order to start a discussion. However, my point is that currently, if you want to have a separate custom file, all you have do is to set and load the custom-file in your init.el I have this at the end of my init-el (as I think many have) ;; ;; Customisations ;; (setq custom-file (locate-user-emacs-file "custom.el")) (load custom-file 'noerror) What I propose is to agree on a default value for custom-file that could potentially be changed by the user in init.el or .emacs and do the (load custom-file 'noerror) after loading the init file as a default behaviour for Emacs Having a separate customisation file by default can ease debugging, resetting customisations, bookkeeping, etc. etc. /PA On Mon, 3 Jan 2022 at 15:47, Robert Pluim wrote: > >>>>> On Mon, 3 Jan 2022 07:13:22 +0100, Pedro Andres Aranda Gutierrez < > paaguti@gmail.com> said: > > >> Message: 1 > >> Date: Sun, 02 Jan 2022 20:03:13 +0800 > >> From: Po Lu > >> To: xenodasein--- via "Emacs development discussions." > Pedro> > >> Cc: xenodasein@tutanota.de > >> Subject: Re: Propose to add setup-wizard.el to ELPA > >> Message-ID: <87v8z2jqf2.fsf@yahoo.com> > > Pedro> If the default custom file has always been the init file, mayb= e > the > Pedro> idea could be to create the custom file separately in a defaul= t > Pedro> location instead and keep init and custom files separated. I > don't > Pedro> remember when I started using /custom.el as my cust= om > Pedro> file. Maybe something like that could be made the new default > custom > Pedro> file and /init.el the default init file instead of > ~/.emacs > > The latter is already kind of the case: if /init.el exists > and ~/.emacs doesn=CA=BCt, init.el is used. If you=CA=BCre proposing swap= ping > that so that init.el is used even if .emacs exists, then that=CA=BCs neve= r > going to fly, but I for one would have no objections to customize > saving stuff to init.el if the user has no config at all. But I=CA=BCd le= t > someone else write and test the code :-) > > Robert > -- > --=20 Fragen sind nicht da um beantwortet zu werden, Fragen sind da um gestellt zu werden Georg Kreisler --00000000000092204705d4bb8c9e Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Hi,

I know that dropping .em= acs altogether might be radical. I was trying to tease in order to start a = discussion.
However, my point is that currently, if you want to h= ave a separate custom file, all you have do is to set and load the custom-f= ile in your init.el
I have this at the end of my init-el (as= I think many have)

;;
;; Customisations
;;<= br>(setq custom-file (locate-user-emacs-file "custom.el"))
(lo= ad custom-file 'noerror)

What I propose is to = agree on a default value for custom-file that could potentially be changed = by the user in=C2=A0 init.el or .emacs
and do the (load custo= m-file 'noerror) after loading the init file as a default behaviour for= Emacs

Having a separate customisation file by def= ault can ease debugging, resetting customisations, bookkeeping, etc. etc.
/PA




On M= on, 3 Jan 2022 at 15:47, Robert Pluim <rpluim@gmail.com> wrote:
>>>>> On Mon, 3 Jan 2022 07:13:22 +0100, = Pedro Andres Aranda Gutierrez <paaguti@gmail.com> said:

=C2=A0 =C2=A0 >> Message: 1
=C2=A0 =C2=A0 >> Date: Sun, 02 Jan 2022 20:03:13 +0800
=C2=A0 =C2=A0 >> From: Po Lu <luangruo@yahoo.com>
=C2=A0 =C2=A0 >> To: xenodasein--- via "Emacs development discus= sions."
=C2=A0 =C2=A0 Pedro>=C2=A0 =C2=A0 <emacs-devel@gnu.org>
=C2=A0 =C2=A0 >> Cc: xenodasein@tutanota.de
=C2=A0 =C2=A0 >> Subject: Re: Propose to add setup-wizard.el to ELPA<= br> =C2=A0 =C2=A0 >> Message-ID: <87v8z2jqf2.fsf@yahoo.com>

=C2=A0 =C2=A0 Pedro> If the default custom file has always been the init= file, maybe the
=C2=A0 =C2=A0 Pedro> idea could be to create the custom file separately = in a default
=C2=A0 =C2=A0 Pedro> location instead and keep init and custom files sep= arated. I don't
=C2=A0 =C2=A0 Pedro> remember when I started using <emacs_dir>/cus= tom.el as my custom
=C2=A0 =C2=A0 Pedro> file. Maybe something like that could be made the n= ew default custom
=C2=A0 =C2=A0 Pedro> file and <emacs_dir>/init.el the default init= file instead of ~/.emacs

The latter is already kind of the case: if <emacs_dir>/init.el exists=
and ~/.emacs doesn=CA=BCt, init.el is used. If you=CA=BCre proposing swappi= ng
that so that init.el is used even if .emacs exists, then that=CA=BCs never<= br> going to fly, but I for one would have no objections to customize
saving stuff to init.el if the user has no config at all. But I=CA=BCd let<= br> someone else write and test the code :-)

Robert
--


--
Fragen sin= d nicht da um beantwortet zu werden,
Fragen sind da um gestellt zu= werden
Georg Kreisler
--00000000000092204705d4bb8c9e--