diff options
author | Stefan Monnier <monnier@iro.umontreal.ca> | 2002-11-03 12:37:48 +0000 |
---|---|---|
committer | Stefan Monnier <monnier@iro.umontreal.ca> | 2002-11-03 12:37:48 +0000 |
commit | a85e4d5887bc78a155f7bfdbe0feb978b87c19fd (patch) | |
tree | a65253d4bc1239d3a12abb69d84cf170bb5c9084 /lisp/emacs-lisp/autoload.el | |
parent | 6af7040d52d88a971a092959599af87de9602ca6 (diff) | |
download | emacs-a85e4d5887bc78a155f7bfdbe0feb978b87c19fd.tar.gz |
(generate-file-autoloads, update-file-autoloads): Strip .gz extensions.
(update-autoloads-from-directories): Also consider compressed files.
Diffstat (limited to 'lisp/emacs-lisp/autoload.el')
-rw-r--r-- | lisp/emacs-lisp/autoload.el | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/lisp/emacs-lisp/autoload.el b/lisp/emacs-lisp/autoload.el index 3b6e7d46bdb..0503d908fdd 100644 --- a/lisp/emacs-lisp/autoload.el +++ b/lisp/emacs-lisp/autoload.el @@ -257,7 +257,7 @@ are used." (let ((outbuf (current-buffer)) (autoloads-done '()) (load-name (let ((name (file-name-nondirectory file))) - (if (string-match "\\.elc?$" name) + (if (string-match "\\.elc?\\(\\.\\|$\\)" name) (substring name 0 (match-beginning 0)) name))) (print-length nil) @@ -360,7 +360,7 @@ are used." Return FILE if there was no autoload cookie in it." (interactive "fUpdate autoloads for file: ") (let ((load-name (let ((name (file-name-nondirectory file))) - (if (string-match "\\.elc?$" name) + (if (string-match "\\.elc?\\(\\.\\|$\\)" name) (substring name 0 (match-beginning 0)) name))) (found nil) @@ -480,11 +480,14 @@ Autoload section for %s is up to date." Update loaddefs.el with all the current autoloads from DIRS, and no old ones. This uses `update-file-autoloads' (which see) do its work." (interactive "DUpdate autoloads from directory: ") - (let* ((files (apply 'nconc + (let* ((files-re (let ((tmp nil)) + (dolist (suf load-suffixes + (concat "^[^=.].*" (regexp-opt tmp t) "\\'")) + (unless (string-match "\\.elc" suf) (push suf tmp))))) + (files (apply 'nconc (mapcar (lambda (dir) (directory-files (expand-file-name dir) - ;; FIXME: add .gz etc... - t "^[^=.].*\\.el\\'")) + t files-re)) dirs))) (this-time (current-time)) (no-autoloads nil) ;files with no autoload cookies. |