emacs-devel
[Top][All Lists]
Advanced

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

Re: "Emacs Lisp Packages" chapter in the Emacs manual


From: Stefan Monnier
Subject: Re: "Emacs Lisp Packages" chapter in the Emacs manual
Date: Mon, 11 May 2020 11:09:56 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux)

> 1) Since people will search for "install" in the manual and the most
> relevant section is Packages we need to add a line and a link to the section
> about loading files and having them in the load path.
>
> I did that already.

Good.

> 2) Now, it seems that there is no consensus about what to put in the init
> file to have that file load automatically when emacs starts, which is what
> a user would like to do.

[ The first step is of course to make sure the file is found from
  `load-path`.  ]

If the file is needed simply because the user decided to split their
`.emacs` file into several separate files, then `load` (or `require`) is
probably fine.  That is the case where the file is a configuration
file, i.e. loading it changes Emacs's behavior.

If OTOH that other file is a package/library which provides a particular
feature (in which case, loading the file *should not* change Emacs's
behavior), then usually what should be done is add a few `autoload`s to
load the file on-demand.


        Stefan




reply via email to

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