From e2b6138f1097a5233a45ed4ea1cd7086503b585b Mon Sep 17 00:00:00 2001 From: Roland McGrath Date: Wed, 14 Apr 1993 19:56:19 +0000 Subject: (update-file-autoloads, update-directory-autoloads): If called interactively, save generated-autoload-file when done. --- lisp/emacs-lisp/autoload.el | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'lisp/emacs-lisp/autoload.el') 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." (goto-char output-end) (insert generate-autoload-section-trailer))) (message "Generating autoloads for %s...done" file))) - + (defconst generated-autoload-file "loaddefs.el" "*File \\[update-file-autoloads] puts autoloads into. A .el file can set this in its local variables section to make its @@ -270,6 +270,7 @@ Then do \\[exit-recursive-edit]." (recursive-edit) (beginning-of-line)) (generate-file-autoloads file))) + (if (interactive-p) (save-buffer)) (if (and (null existing-buffer) (setq existing-buffer (get-file-buffer file))) (kill-buffer existing-buffer))))) @@ -312,7 +313,11 @@ file \"%s\") doesn't exist. Remove its autoload section? " "Run \\[update-file-autoloads] on each .el file in DIR." (interactive "DUpdate autoloads for directory: ") (mapcar 'update-file-autoloads - (directory-files dir nil "\\.el$"))) + (directory-files dir nil "\\.el$")) + (if (interactive-p) + (save-excursion + (set-buffer (find-file-noselect generated-autoload-file)) + (save-buffer)))) ;;;###autoload (defun batch-update-autoloads () -- cgit v1.2.1