diff options
| author | Glenn Morris | 2008-06-05 02:37:06 +0000 |
|---|---|---|
| committer | Glenn Morris | 2008-06-05 02:37:06 +0000 |
| commit | a98f63d48d277ebab72cb38090a48e2799531449 (patch) | |
| tree | 7799bfd6759c8b389d935580e1f9324519d564c2 | |
| parent | 2fe516326c2de4a2d3ce3e03c418fa326a31abcb (diff) | |
| download | emacs-a98f63d48d277ebab72cb38090a48e2799531449.tar.gz emacs-a98f63d48d277ebab72cb38090a48e2799531449.zip | |
(autoload-rubric): New function, extracted from autoload-ensure-default-file.
(autoload-ensure-default-file): Use autoload-rubric.
| -rw-r--r-- | lisp/ChangeLog | 36 | ||||
| -rw-r--r-- | lisp/emacs-lisp/autoload.el | 36 |
2 files changed, 56 insertions, 16 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 05f0001c82b..3ecb91a3bb6 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,3 +1,39 @@ | |||
| 1 | 2008-06-05 Glenn Morris <rgm@gnu.org> | ||
| 2 | |||
| 3 | * emacs-lisp/autoload.el (autoload-rubric): New function, | ||
| 4 | extracted from autoload-ensure-default-file. | ||
| 5 | (autoload-ensure-default-file): Use autoload-rubric. | ||
| 6 | |||
| 7 | * cus-dep.el (generated-custom-dependencies-file): Doc fix. | ||
| 8 | (custom-dependencies-no-scan-regexp): New variable. | ||
| 9 | (custom-make-dependencies): Use with-temp-buffer and autoload-rubric. | ||
| 10 | Don't scan files matching custom-dependencies-no-scan-regexp. | ||
| 11 | Disable undo in the output buffer. Remove kept-new-versions wackiness. | ||
| 12 | |||
| 13 | * finder.el (finder-headmark): Initialize and add doc string. | ||
| 14 | (generated-finder-keywords-file): Doc fix. | ||
| 15 | (finder-no-scan-regexp): New variable. | ||
| 16 | (finder-compile-keywords): Use a single let binding. | ||
| 17 | Disable undo in the output buffer. Use autoload-rubric. | ||
| 18 | Use mapc rather than mapcar. Don't scan files matching | ||
| 19 | finder-no-scan-regexp. Use with-temp-buffer. Use expand-file-name | ||
| 20 | rather than concat. Use directory-files to do regexp matching. | ||
| 21 | No need to require jka-compr. | ||
| 22 | (finder-list-keywords): Remove un-needed set-buffer. Disable undo. | ||
| 23 | (finder-list-matches): Disable undo. | ||
| 24 | (finder-commentary): Use let rather than let*. Disable undo. | ||
| 25 | (finder-current-item): Use zerop. | ||
| 26 | (finder-mode): Use define-derived-mode. | ||
| 27 | (finder-exit): Doc fix. Use dolist. | ||
| 28 | |||
| 29 | * Makefile.in ($(lisp)/cus-load.el): Remove unnecessary rule. | ||
| 30 | (custom-deps): Don't require $(lisp)/cus-load.el. | ||
| 31 | (custom-deps, finder-data): Don't depend on autoloads. | ||
| 32 | Should not be needed now, and doing so was causing make install to | ||
| 33 | re-dump emacs post-bootstrap. | ||
| 34 | (bootstrap-after): Don't run update-elclist, since modifying Makefile.in | ||
| 35 | mid-build forces some things to be rebuilt. | ||
| 36 | |||
| 1 | 2008-06-05 Miles Bader <miles@gnu.org> | 37 | 2008-06-05 Miles Bader <miles@gnu.org> |
| 2 | 38 | ||
| 3 | * face-remap.el (variable-pitch-mode): Autoload. | 39 | * face-remap.el (variable-pitch-mode): Autoload. |
diff --git a/lisp/emacs-lisp/autoload.el b/lisp/emacs-lisp/autoload.el index bbe7904c6e6..343a2ce8edf 100644 --- a/lisp/emacs-lisp/autoload.el +++ b/lisp/emacs-lisp/autoload.el | |||
| @@ -235,25 +235,29 @@ put the output in." | |||
| 235 | (print-escape-nonascii t)) | 235 | (print-escape-nonascii t)) |
| 236 | (print form outbuf))))))) | 236 | (print form outbuf))))))) |
| 237 | 237 | ||
| 238 | (defun autoload-rubric (file &optional type) | ||
| 239 | "Return a string giving the appropriate autoload rubric for FILE. | ||
| 240 | TYPE (default \"autoloads\") is a string stating the type of | ||
| 241 | information contained in FILE." | ||
| 242 | (let ((basename (file-name-nondirectory file))) | ||
| 243 | (concat ";;; " basename | ||
| 244 | " --- automatically extracted " (or type "autoloads") "\n" | ||
| 245 | ";;\n" | ||
| 246 | ";;; Code:\n\n" | ||
| 247 | "\n" | ||
| 248 | "(provide '" (file-name-sans-extension basename) ")\n" | ||
| 249 | ";; Local Variables:\n" | ||
| 250 | ";; version-control: never\n" | ||
| 251 | ";; no-byte-compile: t\n" | ||
| 252 | ";; no-update-autoloads: t\n" | ||
| 253 | ";; End:\n" | ||
| 254 | ";;; " basename | ||
| 255 | " ends here\n"))) | ||
| 256 | |||
| 238 | (defun autoload-ensure-default-file (file) | 257 | (defun autoload-ensure-default-file (file) |
| 239 | "Make sure that the autoload file FILE exists and if not create it." | 258 | "Make sure that the autoload file FILE exists and if not create it." |
| 240 | (unless (file-exists-p file) | 259 | (unless (file-exists-p file) |
| 241 | (let ((basename (file-name-nondirectory file))) | 260 | (write-region (autoload-rubric file) nil file)) |
| 242 | (write-region | ||
| 243 | (concat ";;; " basename | ||
| 244 | " --- automatically extracted autoloads\n" | ||
| 245 | ";;\n" | ||
| 246 | ";;; Code:\n\n" | ||
| 247 | "\n" | ||
| 248 | "(provide '" (file-name-sans-extension basename) ")\n" | ||
| 249 | ";; Local Variables:\n" | ||
| 250 | ";; version-control: never\n" | ||
| 251 | ";; no-byte-compile: t\n" | ||
| 252 | ";; no-update-autoloads: t\n" | ||
| 253 | ";; End:\n" | ||
| 254 | ";;; " basename | ||
| 255 | " ends here\n") | ||
| 256 | nil file))) | ||
| 257 | file) | 261 | file) |
| 258 | 262 | ||
| 259 | (defun autoload-insert-section-header (outbuf autoloads load-name file time) | 263 | (defun autoload-insert-section-header (outbuf autoloads load-name file time) |