aboutsummaryrefslogtreecommitdiffstats
path: root/admin
diff options
context:
space:
mode:
authorGlenn Morris2013-03-09 12:19:41 -0800
committerGlenn Morris2013-03-09 12:19:41 -0800
commit8c39e8217487c352f824c7770430170a877cec07 (patch)
tree0b00cc813898c23a12d0dcd865c8c39494f2acee /admin
parentbc989a58e2412c152c2aef9d35ca103979edebd5 (diff)
downloademacs-8c39e8217487c352f824c7770430170a877cec07.tar.gz
emacs-8c39e8217487c352f824c7770430170a877cec07.zip
* admin/admin.el (add-release-logs): Provide interactive defaults.
Allow specification of the release date.
Diffstat (limited to 'admin')
-rw-r--r--admin/ChangeLog5
-rw-r--r--admin/admin.el23
2 files changed, 20 insertions, 8 deletions
diff --git a/admin/ChangeLog b/admin/ChangeLog
index 6a636091a7c..a47d0d3c2dc 100644
--- a/admin/ChangeLog
+++ b/admin/ChangeLog
@@ -1,3 +1,8 @@
12013-03-09 Glenn Morris <rgm@gnu.org>
2
3 * admin.el (add-release-logs): Provide interactive defaults.
4 Allow specification of the release date.
5
12013-03-05 Paul Eggert <eggert@cs.ucla.edu> 62013-03-05 Paul Eggert <eggert@cs.ucla.edu>
2 7
3 * notes/unicode: Add notes about Emacs source file encoding. 8 * notes/unicode: Add notes about Emacs source file encoding.
diff --git a/admin/admin.el b/admin/admin.el
index e815dfade47..e7ef222f424 100644
--- a/admin/admin.el
+++ b/admin/admin.el
@@ -28,25 +28,32 @@
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(defun add-release-logs (root version &optional date)
32 "Add \"Version VERSION released.\" change log entries in ROOT. 32 "Add \"Version VERSION released.\" change log entries in ROOT.
33Root must be the root of an Emacs source tree." 33Root must be the root of an Emacs source tree.
34 (interactive "DEmacs root directory: \nNVersion number: ") 34Optional argument DATE is the release date, default today."
35 (interactive (list (read-directory-name "Emacs root directory: ")
36 (read-string "Version number: "
37 (format "%s.%s" emacs-major-version
38 emacs-minor-version))
39 (read-string "Release date: "
40 (progn (require 'add-log)
41 (funcall add-log-time-format)))))
35 (setq root (expand-file-name root)) 42 (setq root (expand-file-name root))
36 (unless (file-exists-p (expand-file-name "src/emacs.c" root)) 43 (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)) 44 (error "%s doesn't seem to be the root of an Emacs source tree" root))
38 (require 'add-log) 45 (require 'add-log)
46 (or date (setq date (funcall add-log-time-format)))
39 (let* ((logs (process-lines "find" root "-name" "ChangeLog")) 47 (let* ((logs (process-lines "find" root "-name" "ChangeLog"))
40 (entry (format "%s %s <%s>\n\n\t* Version %s released.\n\n" 48 (entry (format "%s %s <%s>\n\n\t* Version %s released.\n\n"
41 (funcall add-log-time-format) 49 date
42 (or add-log-full-name (user-full-name)) 50 (or add-log-full-name (user-full-name))
43 (or add-log-mailing-address user-mail-address) 51 (or add-log-mailing-address user-mail-address)
44 version))) 52 version)))
45 (dolist (log logs) 53 (dolist (log logs)
46 (unless (string-match "/gnus/" log) 54 (find-file log)
47 (find-file log) 55 (goto-char (point-min))
48 (goto-char (point-min)) 56 (insert entry))))
49 (insert entry)))))
50 57
51(defun set-version-in-file (root file version rx) 58(defun set-version-in-file (root file version rx)
52 (find-file (expand-file-name file root)) 59 (find-file (expand-file-name file root))