emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] Fixing package-initialize, adding early init file


From: Stefan Monnier
Subject: Re: [PATCH] Fixing package-initialize, adding early init file
Date: Tue, 19 Sep 2017 08:30:44 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/26.0.50 (gnu/linux)

> Attached is a preliminary patch for fixing "the package-initialize
> problem" (see [1] [2] [3]) by adding an early init file. Feedback
> welcome. In particular,

Thanks, comments below.

>  ;;;###autoload
>  (defun package-initialize (&optional no-activate)
[...]
> +  (setq package-enable-at-startup nil)

BTW, in a subsequent patch we could rename this to package-initialized,
so the name reflects what the variable contains rather than what it's
used for.

> +  DEFVAR_LISP ("early-init-file", Vearly_init_file,
> +               doc: /* File name, including directory, of user's early init 
> file.
> +If the file loaded had extension `.elc', and the corresponding source file
> +exists, this variable contains the name of source file, suitable for use
> +by functions like `custom-save-all' which edit the init file.
> +While Emacs loads and evaluates the init file, value is the real name
> +of the file, regardless of whether or not it has the `.elc' extension.  */);
> +  Vearly_init_file = Qnil;

This is not used from C code, so make it a plain old defvar in startup.el.

I haven't yet looked at the startup.el part, sorry.


        Stefan




reply via email to

[Prev in Thread] Current Thread [Next in Thread]