aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRoland McGrath1993-04-14 19:56:19 +0000
committerRoland McGrath1993-04-14 19:56:19 +0000
commite2b6138f1097a5233a45ed4ea1cd7086503b585b (patch)
tree92d739c82c2604f2b99237b826cf2bbdf0d3bdbe
parent5c2946c73b11d9eedc7527d7353b55a7b8988ca7 (diff)
downloademacs-e2b6138f1097a5233a45ed4ea1cd7086503b585b.tar.gz
emacs-e2b6138f1097a5233a45ed4ea1cd7086503b585b.zip
(update-file-autoloads, update-directory-autoloads): If called
interactively, save generated-autoload-file when done.
-rw-r--r--lisp/emacs-lisp/autoload.el9
1 files changed, 7 insertions, 2 deletions
diff --git a/lisp/emacs-lisp/autoload.el b/lisp/emacs-lisp/autoload.el
index d863435de38..364289d1df7 100644
--- a/lisp/emacs-lisp/autoload.el
+++ b/lisp/emacs-lisp/autoload.el
@@ -208,7 +208,7 @@ are used."
208 (goto-char output-end) 208 (goto-char output-end)
209 (insert generate-autoload-section-trailer))) 209 (insert generate-autoload-section-trailer)))
210 (message "Generating autoloads for %s...done" file))) 210 (message "Generating autoloads for %s...done" file)))
211 211
212(defconst generated-autoload-file "loaddefs.el" 212(defconst generated-autoload-file "loaddefs.el"
213 "*File \\[update-file-autoloads] puts autoloads into. 213 "*File \\[update-file-autoloads] puts autoloads into.
214A .el file can set this in its local variables section to make its 214A .el file can set this in its local variables section to make its
@@ -270,6 +270,7 @@ Then do \\[exit-recursive-edit]."
270 (recursive-edit) 270 (recursive-edit)
271 (beginning-of-line)) 271 (beginning-of-line))
272 (generate-file-autoloads file))) 272 (generate-file-autoloads file)))
273 (if (interactive-p) (save-buffer))
273 (if (and (null existing-buffer) 274 (if (and (null existing-buffer)
274 (setq existing-buffer (get-file-buffer file))) 275 (setq existing-buffer (get-file-buffer file)))
275 (kill-buffer existing-buffer))))) 276 (kill-buffer existing-buffer)))))
@@ -312,7 +313,11 @@ file \"%s\") doesn't exist. Remove its autoload section? "
312 "Run \\[update-file-autoloads] on each .el file in DIR." 313 "Run \\[update-file-autoloads] on each .el file in DIR."
313 (interactive "DUpdate autoloads for directory: ") 314 (interactive "DUpdate autoloads for directory: ")
314 (mapcar 'update-file-autoloads 315 (mapcar 'update-file-autoloads
315 (directory-files dir nil "\\.el$"))) 316 (directory-files dir nil "\\.el$"))
317 (if (interactive-p)
318 (save-excursion
319 (set-buffer (find-file-noselect generated-autoload-file))
320 (save-buffer))))
316 321
317;;;###autoload 322;;;###autoload
318(defun batch-update-autoloads () 323(defun batch-update-autoloads ()