diff options
Diffstat (limited to 'admin/admin.el')
| -rw-r--r-- | admin/admin.el | 85 |
1 files changed, 69 insertions, 16 deletions
diff --git a/admin/admin.el b/admin/admin.el index e815dfade47..cb7eaead27f 100644 --- a/admin/admin.el +++ b/admin/admin.el | |||
| @@ -28,25 +28,38 @@ | |||
| 28 | 28 | ||
| 29 | (defvar add-log-time-format) ; in add-log | 29 | (defvar add-log-time-format) ; in add-log |
| 30 | 30 | ||
| 31 | (defun add-release-logs (root version) | 31 | ;; Does this information need to be in every ChangeLog, as opposed to |
| 32 | ;; just the top-level one? Only if you allow changes the same | ||
| 33 | ;; day as the release. | ||
| 34 | ;; http://lists.gnu.org/archive/html/emacs-devel/2013-03/msg00161.html | ||
| 35 | (defun add-release-logs (root version &optional date) | ||
| 32 | "Add \"Version VERSION released.\" change log entries in ROOT. | 36 | "Add \"Version VERSION released.\" change log entries in ROOT. |
| 33 | Root must be the root of an Emacs source tree." | 37 | Root must be the root of an Emacs source tree. |
| 34 | (interactive "DEmacs root directory: \nNVersion number: ") | 38 | Optional argument DATE is the release date, default today." |
| 39 | (interactive (list (read-directory-name "Emacs root directory: ") | ||
| 40 | (read-string "Version number: " | ||
| 41 | (format "%s.%s" emacs-major-version | ||
| 42 | emacs-minor-version)) | ||
| 43 | (read-string "Release date: " | ||
| 44 | (progn (require 'add-log) | ||
| 45 | (let ((add-log-time-zone-rule t)) | ||
| 46 | (funcall add-log-time-format)))))) | ||
| 35 | (setq root (expand-file-name root)) | 47 | (setq root (expand-file-name root)) |
| 36 | (unless (file-exists-p (expand-file-name "src/emacs.c" root)) | 48 | (unless (file-exists-p (expand-file-name "src/emacs.c" root)) |
| 37 | (error "%s doesn't seem to be the root of an Emacs source tree" root)) | 49 | (error "%s doesn't seem to be the root of an Emacs source tree" root)) |
| 38 | (require 'add-log) | 50 | (require 'add-log) |
| 51 | (or date (setq date (let ((add-log-time-zone-rule t)) | ||
| 52 | (funcall add-log-time-format)))) | ||
| 39 | (let* ((logs (process-lines "find" root "-name" "ChangeLog")) | 53 | (let* ((logs (process-lines "find" root "-name" "ChangeLog")) |
| 40 | (entry (format "%s %s <%s>\n\n\t* Version %s released.\n\n" | 54 | (entry (format "%s %s <%s>\n\n\t* Version %s released.\n\n" |
| 41 | (funcall add-log-time-format) | 55 | date |
| 42 | (or add-log-full-name (user-full-name)) | 56 | (or add-log-full-name (user-full-name)) |
| 43 | (or add-log-mailing-address user-mail-address) | 57 | (or add-log-mailing-address user-mail-address) |
| 44 | version))) | 58 | version))) |
| 45 | (dolist (log logs) | 59 | (dolist (log logs) |
| 46 | (unless (string-match "/gnus/" log) | 60 | (find-file log) |
| 47 | (find-file log) | 61 | (goto-char (point-min)) |
| 48 | (goto-char (point-min)) | 62 | (insert entry)))) |
| 49 | (insert entry))))) | ||
| 50 | 63 | ||
| 51 | (defun set-version-in-file (root file version rx) | 64 | (defun set-version-in-file (root file version rx) |
| 52 | (find-file (expand-file-name file root)) | 65 | (find-file (expand-file-name file root)) |
| @@ -215,17 +228,33 @@ Root must be the root of an Emacs source tree." | |||
| 215 | (manual-pdf texi (expand-file-name "elisp.pdf" dest)) | 228 | (manual-pdf texi (expand-file-name "elisp.pdf" dest)) |
| 216 | (manual-dvi texi (expand-file-name "elisp.dvi" dvi-dir) | 229 | (manual-dvi texi (expand-file-name "elisp.dvi" dvi-dir) |
| 217 | (expand-file-name "elisp.ps" ps-dir))) | 230 | (expand-file-name "elisp.ps" ps-dir))) |
| 231 | (let ((texi (expand-file-name "doc/lispintro/emacs-lisp-intro.texi" root)) | ||
| 232 | (dest (expand-file-name "emacs-lisp-intro" dest)) | ||
| 233 | dest2 dest3) | ||
| 234 | ;; Mimic the atypical directory layout used for emacs-lisp-intro. | ||
| 235 | (make-directory dest) | ||
| 236 | (make-directory (setq dest2 (expand-file-name "html_node" dest))) | ||
| 237 | (manual-html-node texi dest2) | ||
| 238 | (make-directory (setq dest2 (expand-file-name "html_mono" dest))) | ||
| 239 | (manual-html-mono texi (expand-file-name "emacs-lisp-intro.html" dest2)) | ||
| 240 | (make-directory (setq dest2 (expand-file-name "txt" dest))) | ||
| 241 | (manual-txt texi (expand-file-name "emacs-lisp-intro.txt" dest2)) | ||
| 242 | (manual-pdf texi (expand-file-name "emacs-lisp-intro.pdf" dest)) | ||
| 243 | (make-directory (setq dest2 (expand-file-name "dvi" dest))) | ||
| 244 | (make-directory (setq dest3 (expand-file-name "ps" dest))) | ||
| 245 | (manual-dvi texi (expand-file-name "emacs-lisp-intro.dvi" dest2) | ||
| 246 | (expand-file-name "emacs-lisp-intro.ps" dest3))) | ||
| 218 | ;; Misc manuals | 247 | ;; Misc manuals |
| 219 | (let ((manuals '("ada-mode" "auth" "autotype" "calc" "cc-mode" | 248 | (let ((manuals '("ada-mode" "auth" "autotype" "bovine" "calc" "cc-mode" |
| 220 | "cl" "dbus" "dired-x" "ebrowse" "ede" "ediff" | 249 | "cl" "dbus" "dired-x" "ebrowse" "ede" "ediff" |
| 221 | "edt" "eieio" "emacs-mime" "epa" "erc" "ert" | 250 | "edt" "eieio" "emacs-gnutls" "emacs-mime" "epa" "erc" "ert" |
| 222 | "eshell" "eudc" "faq" "flymake" "forms" | 251 | "eshell" "eudc" "faq" "flymake" "forms" |
| 223 | "gnus" "emacs-gnutls" "idlwave" "info" | 252 | "gnus" "htmlfontify" "idlwave" "info" |
| 224 | "mairix-el" "message" "mh-e" "newsticker" | 253 | "mairix-el" "message" "mh-e" "newsticker" |
| 225 | "nxml-mode" "org" "pcl-cvs" "pgg" "rcirc" | 254 | "nxml-mode" "org" "pcl-cvs" "pgg" "rcirc" |
| 226 | "remember" "reftex" "sasl" "sc" "semantic" | 255 | "reftex" "remember" "sasl" "sc" "semantic" |
| 227 | "ses" "sieve" "smtpmail" "speedbar" "tramp" | 256 | "ses" "sieve" "smtpmail" "speedbar" "srecode" "tramp" |
| 228 | "url" "vip" "viper" "widget" "woman"))) | 257 | "url" "vip" "viper" "widget" "wisent" "woman"))) |
| 229 | (dolist (manual manuals) | 258 | (dolist (manual manuals) |
| 230 | (manual-misc-html manual root html-node-dir html-mono-dir))) | 259 | (manual-misc-html manual root html-node-dir html-mono-dir))) |
| 231 | (message "Manuals created in %s" dest))) | 260 | (message "Manuals created in %s" dest))) |
| @@ -256,6 +285,11 @@ This function also edits the HTML files so that they validate as | |||
| 256 | HTML 4.01 Transitional, and pulls in the gnu.org stylesheet using | 285 | HTML 4.01 Transitional, and pulls in the gnu.org stylesheet using |
| 257 | the @import directive." | 286 | the @import directive." |
| 258 | (call-process "makeinfo" nil nil nil | 287 | (call-process "makeinfo" nil nil nil |
| 288 | "-D" "WWW_GNU_ORG" | ||
| 289 | "-I" (expand-file-name "../emacs" | ||
| 290 | (file-name-directory texi-file)) | ||
| 291 | "-I" (expand-file-name "../misc" | ||
| 292 | (file-name-directory texi-file)) | ||
| 259 | "--html" "--no-split" texi-file "-o" dest) | 293 | "--html" "--no-split" texi-file "-o" dest) |
| 260 | (with-temp-buffer | 294 | (with-temp-buffer |
| 261 | (insert-file-contents dest) | 295 | (insert-file-contents dest) |
| @@ -277,6 +311,11 @@ the @import directive." | |||
| 277 | (unless (file-exists-p texi-file) | 311 | (unless (file-exists-p texi-file) |
| 278 | (error "Manual file %s not found" texi-file)) | 312 | (error "Manual file %s not found" texi-file)) |
| 279 | (call-process "makeinfo" nil nil nil | 313 | (call-process "makeinfo" nil nil nil |
| 314 | "-D" "WWW_GNU_ORG" | ||
| 315 | "-I" (expand-file-name "../emacs" | ||
| 316 | (file-name-directory texi-file)) | ||
| 317 | "-I" (expand-file-name "../misc" | ||
| 318 | (file-name-directory texi-file)) | ||
| 280 | "--html" texi-file "-o" dir) | 319 | "--html" texi-file "-o" dir) |
| 281 | ;; Loop through the node files, fixing them up. | 320 | ;; Loop through the node files, fixing them up. |
| 282 | (dolist (f (directory-files dir nil "\\.html\\'")) | 321 | (dolist (f (directory-files dir nil "\\.html\\'")) |
| @@ -308,17 +347,31 @@ the @import directive." | |||
| 308 | (defun manual-txt (texi-file dest) | 347 | (defun manual-txt (texi-file dest) |
| 309 | "Run Makeinfo on TEXI-FILE, emitting plaintext output to DEST." | 348 | "Run Makeinfo on TEXI-FILE, emitting plaintext output to DEST." |
| 310 | (call-process "makeinfo" nil nil nil | 349 | (call-process "makeinfo" nil nil nil |
| 350 | "-I" (expand-file-name "../emacs" | ||
| 351 | (file-name-directory texi-file)) | ||
| 352 | "-I" (expand-file-name "../misc" | ||
| 353 | (file-name-directory texi-file)) | ||
| 311 | "--plaintext" "--no-split" texi-file "-o" dest) | 354 | "--plaintext" "--no-split" texi-file "-o" dest) |
| 312 | (shell-command (concat "gzip -c " dest " > " (concat dest ".gz")))) | 355 | (shell-command (concat "gzip -c " dest " > " (concat dest ".gz")))) |
| 313 | 356 | ||
| 314 | (defun manual-pdf (texi-file dest) | 357 | (defun manual-pdf (texi-file dest) |
| 315 | "Run texi2pdf on TEXI-FILE, emitting plaintext output to DEST." | 358 | "Run texi2pdf on TEXI-FILE, emitting plaintext output to DEST." |
| 316 | (call-process "texi2pdf" nil nil nil texi-file "-o" dest)) | 359 | (call-process "texi2pdf" nil nil nil |
| 360 | "-I" (expand-file-name "../emacs" | ||
| 361 | (file-name-directory texi-file)) | ||
| 362 | "-I" (expand-file-name "../misc" | ||
| 363 | (file-name-directory texi-file)) | ||
| 364 | texi-file "-o" dest)) | ||
| 317 | 365 | ||
| 318 | (defun manual-dvi (texi-file dest ps-dest) | 366 | (defun manual-dvi (texi-file dest ps-dest) |
| 319 | "Run texi2dvi on TEXI-FILE, emitting dvi output to DEST. | 367 | "Run texi2dvi on TEXI-FILE, emitting dvi output to DEST. |
| 320 | Also generate PostScript output in PS-DEST." | 368 | Also generate PostScript output in PS-DEST." |
| 321 | (call-process "texi2dvi" nil nil nil texi-file "-o" dest) | 369 | (call-process "texi2dvi" nil nil nil |
| 370 | "-I" (expand-file-name "../emacs" | ||
| 371 | (file-name-directory texi-file)) | ||
| 372 | "-I" (expand-file-name "../misc" | ||
| 373 | (file-name-directory texi-file)) | ||
| 374 | texi-file "-o" dest) | ||
| 322 | (call-process "dvips" nil nil nil dest "-o" ps-dest) | 375 | (call-process "dvips" nil nil nil dest "-o" ps-dest) |
| 323 | (call-process "gzip" nil nil nil dest) | 376 | (call-process "gzip" nil nil nil dest) |
| 324 | (call-process "gzip" nil nil nil ps-dest)) | 377 | (call-process "gzip" nil nil nil ps-dest)) |