[Top][All Lists]

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

Autoloads and subdirectories

From: Clément Pit--Claudel
Subject: Autoloads and subdirectories
Date: Sat, 28 May 2016 00:25:09 -0400
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.8.0

Hi emacs-devel,

What is the proper way to organize the sources of a multi-file package into 
subdirectories, without breaking autoloads? As far as I can see 
`update-directory-autoloads` doesn't explore subdirectories recursively (in 
fact, it is documented not to), and package.el doesn't call it on 
subdirectories of a package's content directory. And yet, the manual says 
(emphasis mine):

> Do not include any file named name-autoloads.el. This file is 
> reserved for the package’s autoload definitions (see Packaging 
> Basics). It is created automatically when the package is installed, 
> by searching *all the Lisp files* in the package for autoload magic 
> comments.

This claims that all files in the package are searched (which sounds nice, but 
seems incorrect).  Presumably this is just imprecise wording, since Packaging 
Basics does say the following:

> Emacs then searches every Lisp file in the content directory for
> autoload magic comments (see Autoload). These autoload definitions
> are saved to a file named name-autoloads.el in the content directory.

Which brings me back to square one: how do I move parts of a package to a 
subdirectory, without breaking their autoloads?


Attachment: signature.asc
Description: OpenPGP digital signature

reply via email to

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