aboutsummaryrefslogtreecommitdiffstats
path: root/admin
diff options
context:
space:
mode:
authorPaul Eggert2015-04-07 00:00:55 -0700
committerPaul Eggert2015-04-07 00:00:55 -0700
commit23468561682aea0705249a469f614bb873e4f411 (patch)
tree0f9627efff11eaec69cbe91a730ccfdda2f1396e /admin
parentdd1404cca3cf6bc459bc53f9aa9528170e30efd4 (diff)
downloademacs-23468561682aea0705249a469f614bb873e4f411.tar.gz
emacs-23468561682aea0705249a469f614bb873e4f411.zip
Generate a ChangeLog file from commit logs
* .gitignore: Add 'ChangeLog'. * build-aux/gitlog-to-changelog: New file, from Gnulib. * build-aux/gitlog-to-emacslog: New file. * CONTRIBUTE: Document the revised workflow. * Makefile.in (clean): Remove *.tmp and etc/*.tmp* instead of just special cases. (CHANGELOG_HISTORY_INDEX_MAX, CHANGELOG_N, gen_origin): New vars. (ChangeLog, unchanged-history-files, change-history) (change-history-commit): New rules. * admin/admin.el (make-manuals-dist--1): Don't worry about doc/ChangeLog. * admin/authors.el: Add a FIXME. * admin/make-tarball.txt: * lisp/calendar/icalendar.el: * lisp/gnus/deuglify.el: * lisp/obsolete/gulp.el: * lwlib/README: Adjust to renamed ChangeLog history files. * admin/merge-gnulib (GNULIB_MODULES): Add gitlog-to-changelog. * admin/notes/repo: Call it 'master' a la Git, not 'trunk' a la Bzr. Remove obsolete discussion of merging ChangeLog files. New section "Maintaining ChangeLog history". * build-aux/git-hooks/pre-commit: Reject attempts to commit files named 'ChangeLog'. * lib/gnulib.mk, m4/gnulib-comp.m4: Regenerate. * make-dist: Make and distribute top-level ChangeLog if there's a .git directory. Distribute the new ChangeLog history files instead of scattered ChangeLog files. Distribute the new files gitlog-to-changelog and gitlog-to-emacslog. Fixes: bug#19113
Diffstat (limited to 'admin')
-rw-r--r--admin/admin.el6
-rw-r--r--admin/authors.el5
-rw-r--r--admin/make-tarball.txt24
-rwxr-xr-xadmin/merge-gnulib2
-rw-r--r--admin/notes/repo54
5 files changed, 52 insertions, 39 deletions
diff --git a/admin/admin.el b/admin/admin.el
index 9bf503ef142..f7b915509fb 100644
--- a/admin/admin.el
+++ b/admin/admin.el
@@ -28,10 +28,6 @@
28 28
29(defvar add-log-time-format) ; in add-log 29(defvar add-log-time-format) ; in add-log
30 30
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) 31(defun add-release-logs (root version &optional date)
36 "Add \"Version VERSION released.\" change log entries in ROOT. 32 "Add \"Version VERSION released.\" change log entries in ROOT.
37Root must be the root of an Emacs source tree. 33Root must be the root of an Emacs source tree.
@@ -601,7 +597,7 @@ style=\"text-align:left\">")
601 (copy-file "../doc/misc/texinfo.tex" stem) 597 (copy-file "../doc/misc/texinfo.tex" stem)
602 (or (equal type "emacs") (copy-file "../doc/emacs/emacsver.texi" stem)) 598 (or (equal type "emacs") (copy-file "../doc/emacs/emacsver.texi" stem))
603 (dolist (file (directory-files (format "../doc/%s" type) t)) 599 (dolist (file (directory-files (format "../doc/%s" type) t))
604 (if (or (string-match-p "\\(\\.texi\\'\\|/ChangeLog\\|/README\\'\\)" file) 600 (if (or (string-match-p "\\(\\.texi\\'\\|/README\\'\\)" file)
605 (and (equal type "lispintro") 601 (and (equal type "lispintro")
606 (string-match-p "\\.\\(eps\\|pdf\\)\\'" file))) 602 (string-match-p "\\.\\(eps\\|pdf\\)\\'" file)))
607 (copy-file file stem))) 603 (copy-file file stem)))
diff --git a/admin/authors.el b/admin/authors.el
index 1e4af9bbace..1f7e542478b 100644
--- a/admin/authors.el
+++ b/admin/authors.el
@@ -27,6 +27,9 @@
27;; Use M-x authors RET to create an *Authors* buffer that can used as 27;; Use M-x authors RET to create an *Authors* buffer that can used as
28;; or merged with Emacs's AUTHORS file. 28;; or merged with Emacs's AUTHORS file.
29 29
30;; FIXME: This needs to modernized in the light of current practice,
31;; which generates a single top-level ChangeLog file from commit logs.
32
30;;; Code: 33;;; Code:
31 34
32(defvar authors-coding-system 'utf-8 35(defvar authors-coding-system 'utf-8
@@ -76,7 +79,7 @@ files.")
76 ("Gerd Möllmann" "Gerd Moellmann") 79 ("Gerd Möllmann" "Gerd Moellmann")
77 ("Hallvard B. Furuseth" "Hallvard B Furuseth" "Hallvard Furuseth") 80 ("Hallvard B. Furuseth" "Hallvard B Furuseth" "Hallvard Furuseth")
78 ("Hrvoje Nikšić" "Hrvoje Niksic") 81 ("Hrvoje Nikšić" "Hrvoje Niksic")
79 ;; lisp/org/ChangeLog 2010-11-11. 82 ;; lisp/org/ChangeLog.1 2010-11-11.
80 (nil "aaa bbb") 83 (nil "aaa bbb")
81 (nil "Code Extracted") ; lisp/newcomment.el's "Author:" header 84 (nil "Code Extracted") ; lisp/newcomment.el's "Author:" header
82 ("Jaeyoun Chung" "Jae-youn Chung" "Jae-you Chung" "Chung Jae-youn") 85 ("Jaeyoun Chung" "Jae-youn Chung" "Jae-you Chung" "Chung Jae-youn")
diff --git a/admin/make-tarball.txt b/admin/make-tarball.txt
index e902b023f80..8190e9edb85 100644
--- a/admin/make-tarball.txt
+++ b/admin/make-tarball.txt
@@ -31,28 +31,33 @@ General steps (for each step, check for possible errors):
31 M-x authors RET 31 M-x authors RET
32 32
33 If there is an "*Authors Errors*" buffer, address the issues. 33 If there is an "*Authors Errors*" buffer, address the issues.
34 If there was a ChangeLog typo, fix it. If a file was deleted or 34 If there was a ChangeLog typo, run "make change-history" and then
35 renamed, consider adding an appropriate entry to authors-ignored-files, 35 fix the newest ChangeLog history file. If a file was deleted or
36 authors-valid-file-names, or authors-renamed-files-alist. 36 renamed, consider adding an appropriate entry to
37 authors-ignored-files, authors-valid-file-names, or
38 authors-renamed-files-alist.
37 39
38 If necessary, repeat M-x authors after making those changes. 40 If necessary, repeat M-x authors after making those changes.
39 Save the "*Authors*" buffer as etc/AUTHORS. 41 Save the "*Authors*" buffer as etc/AUTHORS.
40 Check the diff looks reasonable. Maybe add entries to 42 Check the diff looks reasonable. Maybe add entries to
41 authors-ambiguous-files or authors-aliases, and repeat. 43 authors-ambiguous-files or authors-aliases, and repeat.
42 Commit any fixes to ChangeLogs or authors.el. 44 Commit any fixes to authors.el.
43 45
443. Set the version number (M-x load-file RET admin/admin.el RET, then 463. Set the version number (M-x load-file RET admin/admin.el RET, then
45 M-x set-version RET). For a release, add released ChangeLog 47 M-x set-version RET). For a release, add released ChangeLog
46 entries (M-x add-release-logs RET). 48 entries (create a ChangeLog symlink a la vc-dwim, then run M-x
49 add-release-logs RET, then run the shell command 'vc-dwim --commit').
47 50
48 For a pretest, start at version .90. After .99, use .990 (so that 51 For a pretest, start at version .90. After .99, use .990 (so that
49 it sorts). 52 it sorts).
50 53
51 The final pretest should be a release candidate. Set the version 54 The final pretest should be a release candidate. Set the version
52 number to that of the actual release. Pick a date about a week 55 number to that of the actual release. Pick a date about a week
53 from now when you intend to make the release. Use M-x add-release-logs 56 from now when you intend to make the release. Use vc-dwim and
54 to add the ChangeLog entries for that date to the tar file (but 57 M-x add-release-logs as described above to add commit messages
55 do not commit the entries to the repository until the actual release). 58 that will appear in the tarball's automatically-generated ChangeLog
59 file as entries for that date.
60
56 Name the tar file as emacs-XX.Y-rc1.tar. If all goes well in the 61 Name the tar file as emacs-XX.Y-rc1.tar. If all goes well in the
57 following week, you can simply rename the file and use it for the 62 following week, you can simply rename the file and use it for the
58 actual release. If you need another release candidate, remember 63 actual release. If you need another release candidate, remember
@@ -67,8 +72,7 @@ General steps (for each step, check for possible errors):
675. Copy lisp/loaddefs.el to lisp/ldefs-boot.el. 725. Copy lisp/loaddefs.el to lisp/ldefs-boot.el.
68 73
69 Commit etc/AUTHORS, lisp/ldefs-boot.el, and the files changed 74 Commit etc/AUTHORS, lisp/ldefs-boot.el, and the files changed
70 by M-x set-version. For a release, also commit the ChangeLog 75 by M-x set-version.
71 files in all directories.
72 76
73 If someone else made a commit between step 1 and now, 77 If someone else made a commit between step 1 and now,
74 you need to repeat from step 4 onwards. (You can commit the files 78 you need to repeat from step 4 onwards. (You can commit the files
diff --git a/admin/merge-gnulib b/admin/merge-gnulib
index 9e2b10dc4ce..e63422b0d5e 100755
--- a/admin/merge-gnulib
+++ b/admin/merge-gnulib
@@ -31,7 +31,7 @@ GNULIB_MODULES='
31 crypto/md5 crypto/sha1 crypto/sha256 crypto/sha512 31 crypto/md5 crypto/sha1 crypto/sha256 crypto/sha512
32 dtoastr dtotimespec dup2 environ execinfo faccessat 32 dtoastr dtotimespec dup2 environ execinfo faccessat
33 fcntl fcntl-h fdatasync fdopendir filemode fstatat fsync 33 fcntl fcntl-h fdatasync fdopendir filemode fstatat fsync
34 getloadavg getopt-gnu gettime gettimeofday 34 getloadavg getopt-gnu gettime gettimeofday gitlog-to-changelog
35 intprops largefile lstat 35 intprops largefile lstat
36 manywarnings memrchr mkostemp mktime 36 manywarnings memrchr mkostemp mktime
37 pipe2 pselect pthread_sigmask putenv qacl readlink readlinkat 37 pipe2 pselect pthread_sigmask putenv qacl readlink readlinkat
diff --git a/admin/notes/repo b/admin/notes/repo
index 4f9dc59eb0f..f38fd2cc3a8 100644
--- a/admin/notes/repo
+++ b/admin/notes/repo
@@ -10,10 +10,10 @@ instructions.
10* Install changes only on one branch, let them get merged elsewhere if needed. 10* Install changes only on one branch, let them get merged elsewhere if needed.
11 11
12In particular, install bug-fixes only on the release branch (if there 12In particular, install bug-fixes only on the release branch (if there
13is one) and let them get synced to the trunk; do not install them by 13is one) and let them get synced to the master; do not install them by
14hand on the trunk as well. E.g. if there is an active "emacs-24" branch 14hand on the master as well. E.g. if there is an active "emacs-24" branch
15and you have a bug-fix appropriate for the next emacs-24.x release, 15and you have a bug-fix appropriate for the next emacs-24.x release,
16install it only on the emacs-24 branch, not on the trunk as well. 16install it only on the emacs-24 branch, not on the master as well.
17 17
18Installing things manually into more than one branch makes merges more 18Installing things manually into more than one branch makes merges more
19difficult. 19difficult.
@@ -21,10 +21,10 @@ difficult.
21http://lists.gnu.org/archive/html/emacs-devel/2010-03/msg01124.html 21http://lists.gnu.org/archive/html/emacs-devel/2010-03/msg01124.html
22 22
23The exception is, if you know that the change will be difficult to 23The exception is, if you know that the change will be difficult to
24merge to the trunk (eg because the trunk code has changed a lot). 24merge to the master (eg because the master code has changed a lot).
25In that case, it's helpful if you can apply the change to both trunk 25In that case, it's helpful if you can apply the change to both master
26and branch yourself (when committing the branch change, indicate 26and branch yourself (when committing the branch change, indicate
27in the commit log that it should not be merged to the trunk, by 27in the commit log that it should not be merged to the master, by
28including the phrase "Not to be merged to master", or any other phrase 28including the phrase "Not to be merged to master", or any other phrase
29that matches "merge"). 29that matches "merge").
30 30
@@ -32,14 +32,14 @@ that matches "merge").
32 32
33If your branch has only a single commit, or many different real 33If your branch has only a single commit, or many different real
34commits, it is fine to do a merge. If your branch has only a very 34commits, it is fine to do a merge. If your branch has only a very
35small number of "real" commits, but several "merge from trunks", it is 35small number of "real" commits, but several "merge from masters", it is
36preferred that you take your branch's diff, apply it to the trunk, and 36preferred that you take your branch's diff, apply it to the master, and
37commit directly, not merge. This keeps the history cleaner. 37commit directly, not merge. This keeps the history cleaner.
38 38
39In general, when working on some feature in a separate branch, it is 39In general, when working on some feature in a separate branch, it is
40preferable not to merge from trunk until you are done with the 40preferable not to merge from master until you are done with the
41feature. Unless you really need some change that was done on the 41feature. Unless you really need some change that was done on the
42trunk while you were developing on the branch, you don't really need 42master while you were developing on the branch, you don't really need
43those merges; just merge once, when you are done with the feature, and 43those merges; just merge once, when you are done with the feature, and
44Bazaar will take care of the rest. Bazaar is much better in this than 44Bazaar will take care of the rest. Bazaar is much better in this than
45CVS, so interim merges are unnecessary. 45CVS, so interim merges are unnecessary.
@@ -66,22 +66,14 @@ variable in admin/merge-gnulib before running it.
66If you remove a gnulib module, or if a gnulib module 66If you remove a gnulib module, or if a gnulib module
67removes a file, then remove the corresponding files by hand. 67removes a file, then remove the corresponding files by hand.
68 68
69* How to merge changes from emacs-24 to trunk 69* How to merge changes from emacs-24 to master
70 70
71[The section on git merge procedure has not yet been written] 71[The section on git merge procedure has not yet been written.]
72
73Inspect the change log entries (e.g. in case too many entries have been
74included or whitespace between entries needs fixing). If someone made
75multiple change log entries on different days in the branch, you may
76wish to collapse them all to a single entry for that author in the
77trunk (because in the trunk they all appear under the same date).
78Obviously, if there are multiple changes to the same file by different
79authors, don't break the logical ordering in doing this.
80 72
81You may see conflicts in autoload md5sums in comments. Strictly 73You may see conflicts in autoload md5sums in comments. Strictly
82speaking, the right thing to do is merge everything else, resolve the 74speaking, the right thing to do is merge everything else, resolve the
83conflict by choosing either the trunk or branch version, then run 75conflict by choosing either the master or branch version, then run
84`make -C lisp autoloads' to update the md5sums to the correct trunk 76`make -C lisp autoloads' to update the md5sums to the correct master
85value before committing. 77value before committing.
86 78
87* Re-adding a file that has been removed from the repository 79* Re-adding a file that has been removed from the repository
@@ -124,3 +116,21 @@ again.
124 116
125This is a semi-automated way to find the revision that introduced a bug. 117This is a semi-automated way to find the revision that introduced a bug.
126Browse `git help bisect' for technical instructions. 118Browse `git help bisect' for technical instructions.
119
120* Maintaining ChangeLog history
121
122Older ChangeLog entries are kept in history files named ChangeLog.1,
123ChangeLog.2, etc., and can be edited just as any other source files
124can. Newer ChangeLog entries are stored in the repository as commit
125messages, which cannot be edited directly.
126
127'make ChangeLog' copies newer ChangeLog entries into a file
128'ChangeLog' that is intended to be put into the distribution tarball.
129This ChangeLog file is not put into the repository.
130
131'make change-history' copies all newer ChangeLog entries into the
132start of the newest ChangeLog history file. These ChangeLog entries
133are thereafter considered to be old, so later uses of 'make ChangeLog'
134and/or 'make change-history' will no longer copy the entries. To
135alter ChangeLog history, run 'make change-history', then edit
136the ChangeLog history files manually and commit your changes.