Update copyright notices for 2013.
[bpt/emacs.git] / lisp / emacs-lisp / authors.el
1 ;;; authors.el --- utility for maintaining Emacs's AUTHORS file -*-coding: utf-8 -*-
2
3 ;; Copyright (C) 2000-2013 Free Software Foundation, Inc.
4
5 ;; Author: Gerd Moellmann <gerd@gnu.org>
6 ;; Maintainer: Kim F. Storm <storm@cua.dk>
7 ;; Keywords: maint
8 ;; Package: emacs
9
10 ;; This file is part of GNU Emacs.
11
12 ;; GNU Emacs is free software: you can redistribute it and/or modify
13 ;; it under the terms of the GNU General Public License as published by
14 ;; the Free Software Foundation, either version 3 of the License, or
15 ;; (at your option) any later version.
16
17 ;; GNU Emacs is distributed in the hope that it will be useful,
18 ;; but WITHOUT ANY WARRANTY; without even the implied warranty of
19 ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
20 ;; GNU General Public License for more details.
21
22 ;; You should have received a copy of the GNU General Public License
23 ;; along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>.
24
25 ;;; Commentary:
26
27 ;; Use M-x authors RET to create an *Authors* buffer that can used as
28 ;; or merged with Emacs's AUTHORS file.
29
30 ;;; Code:
31
32 (defvar authors-coding-system 'utf-8
33 "Coding system used in the AUTHORS file.")
34
35 (defconst authors-many-files 20
36 "Maximum number of files for which to print individual information.
37 If an author has modified more files, only the names of the most
38 frequently modified files are printed and a count of the additional
39 files.")
40
41 (defconst authors-aliases
42 '(
43 ("Aaron S. Hawley" "Aaron Hawley")
44 ("Alexandru Harsanyi" "Alex Harsanyi")
45 ("Andrew Csillag" "Drew Csillag")
46 ("Anna M. Bigatti" "Anna Bigatti")
47 ("Barry A. Warsaw" "Barry A. Warsaw, Century Computing, Inc."
48 "Barry A. Warsaw, ITB" "Barry Warsaw")
49 ("Bill Carpenter" "WJ Carpenter")
50 ("Bill Mann" "William F. Mann")
51 ("Bill Rozas" "Guillermo J. Rozas")
52 ("Björn Torkelsson" "Bjorn Torkelsson")
53 ("Brian Fox" "Brian J. Fox")
54 ("Brian Sniffen" "Brian T. Sniffen")
55 ("Christoph Wedler" "Christoph.Wedler@sap.com")
56 ("Daniel Pfeiffer" "<Daniel.Pfeiffer@Informatik.START.db.de>"
57 "<Daniel.Pfeiffer@Informatik.START.dbp.de>")
58 ("David Abrahams" "Dave Abrahams")
59 ("David De La Harpe Golden" "David Golden")
60 ("David Gillespie" "Dave Gillespie")
61 ("David Kågedal" "David K..edal")
62 ("David M. Koppelman" "David M. Koppelman, Koppel@Ec?e.Lsu.Edu"
63 "David Koppelman")
64 ("David M. Smith" "David Smith" "David M Smith")
65 ("David O'Toole" "David T. O'Toole")
66 ("Deepak Goel" "D. Goel")
67 ("Ed L. Cashin" "Ed L Cashin")
68 ("Edward M. Reingold" "Ed Reingold" "Edward M Reingold"
69 "Reingold Edward M")
70 ("Eli Zaretskii" "eliz")
71 ("Emilio C. Lopes" "Emilio Lopes")
72 ("Era Eriksson" "Era@Iki.Fi")
73 ("Eric M. Ludlam" "Eric Ludlam")
74 ("Eric S. Raymond" "Eric Raymond")
75 ("Eric Youngdale" "(Eric Youngdale at youngdale@v6550c.nrl.navy.mil)")
76 ("Francis J. Wright" "Dr Francis J. Wright" "Francis Wright")
77 ("François Pinard" "Francois Pinard")
78 ("Francesco Potortì" "Francesco Potorti" "Francesco Potorti`")
79 ("Frederic Pierresteguy" "Fred Pierresteguy")
80 ("Geoff Voelker" "voelker")
81 ("Gerd Möllmann" "Gerd Moellmann")
82 ("Hallvard B. Furuseth" "Hallvard B Furuseth" "Hallvard Furuseth")
83 ("Hrvoje Nikšić" "Hrvoje Niksic")
84 ;; lisp/org/ChangeLog 2010-11-11.
85 (nil "aaa bbb")
86 ;; src/ChangeLog.4, 1994-01-11, since fixed.
87 ;;; (nil "(afs@hplb.hpl.hp.com)")
88 ;; lisp/gnus/ChangeLog.1, 1998-01-15.
89 ;; http://quimby.gnus.org/cgi-bin/cvsweb.cgi/gnus/lisp/gnus-art.el?rev=4.13
90 (nil "<Use-Author-Address-Header@\\[127.1\\]>")
91 (nil "Code Extracted") ; lisp/newcomment.el's "Author:" header
92 (nil "\\`FSF") ; FIXME what is this for - no effect?
93 ;; lisp/gnus/ChangeLog.1, 1997-10-12, since fixed.
94 ;;; (nil "ISO-2022-JP")
95 ("Jaeyoun Chung" "Jae-youn Chung" "Jae-you Chung" "Chung Jae-youn")
96 ("Jan Djärv" "Jan D." "Jan Djarv")
97 ("Jay K. Adams" "jka@ece.cmu.edu" "Jay Adams")
98 ("Jérôme Marant" "Jérôme Marant" "Jerome Marant")
99 ("Jens-Ulrik Holger Petersen" "Jens-Ulrik Petersen")
100 ("Jeremy Bertram Maitin-Shepard" "Jeremy Maitin-Shepard")
101 ("Johan Bockgård" "Johan Bockgard")
102 ("John J Foerch" "John Foerch")
103 ("John W. Eaton" "John Eaton")
104 ("Jonathan I. Kamens" "Jonathan Kamens")
105 ("Joseph Arceneaux" "Joe Arceneaux")
106 ("Joseph M. Kelsey" "Joe Kelsey") ; FIXME ?
107 ("Juan León Lahoz García" "Juan-Leon Lahoz Garcia")
108 ("K. Shane Hartman" "Shane Hartman")
109 ("Kai Großjohann" "Kai Grossjohann" "Kai Großjohann"
110 "Kai.Grossjohann@Cs.Uni-Dortmund.De"
111 "Kai.Grossjohann@Gmx.Net")
112 ("Karl Berry" "K. Berry")
113 ("Károly Lőrentey" "Károly Lőrentey" "Lőrentey Károly")
114 ("Kazushi Marukawa" "Kazushi")
115 ("Ken Manheimer" "Kenneth Manheimer")
116 ("Kenichi Handa" "Ken'ichi Handa" "Kenichi HANDA")
117 ("Kevin Greiner" "Kevin J. Greiner")
118 ("Kim F. Storm" "Kim Storm")
119 ("Kyle Jones" "Kyle E. Jones")
120 ("Lars Magne Ingebrigtsen" "Lars Ingebrigtsen")
121 ("Marcus G. Daniels" "Marcus Daniels")
122 ("Mark D. Baushke" "Mark D Baushke")
123 ("Marko Kohtala" "Kohtala Marko")
124 ("Agustín Martín" "Agustin Martin" "Agustín Martín Domingo")
125 ("Martin Lorentzon" "Martin Lorentzson")
126 ("Matt Swift" "Matthew Swift")
127 ("Maxime Edouard Robert Froumentin" "Max Froumentin")
128 ("Michael R. Mauger" "Michael Mauger")
129 ("Michael D. Ernst" "Michael Ernst")
130 ("Michaël Cadilhac" "Michael Cadilhac")
131 ("Michael I. Bushnell" "Michael I Bushnell" "Michael I. Bushnell, P/Bsg")
132 ("Michael R. Cook" "Michael Cook")
133 ("Michael Sperber" "Michael Sperber \\[Mr. Preprocessor\\]")
134 ("Mikio Nakajima" "Nakajima Mikio")
135 ("Nelson Jose dos Santos Ferreira" "Nelson Ferreira")
136 ("Noorul Islam" "Noorul Islam K M")
137 ("Paul Eggert" "eggert")
138 ("Paul Reilly" "(pmr@legacy.pajato.com)")
139 ("Pavel Janík" "Pavel Janík Ml." "Pavel Janik Ml." "Pavel Janik" "Pavel Janík" "Pavel@Janik.Cz")
140 ("Pavel Kobiakov" "Pavel Kobyakov")
141 ("Per Abrahamsen" "Per Abhiddenware")
142 ("Per Starbäck" "Per Starback")
143 ("Peter J. Weisberg" "PJ Weisberg")
144 ("Peter S. Galbraith" "Peter Galbraith")
145 ("Peter Runestig" "Peter 'luna' Runestig")
146 ("Peter S. Galbraith" "Peter S Galbraith")
147 ("Raja R. Harinath" "Raja R Harinath")
148 ("Richard G. Bielawski" "Richard G Bielawski" "Richard Bielawski")
149 ("Richard King" "Dick King")
150 ("Richard M. Stallman" "Richard M. Stallman,,," "Richard Stallman"
151 "rms" "rms@gnu.org")
152 ("Robert J. Chassell" "Bob Chassell")
153 ("Roland B. Roberts" "Roland B Roberts" "Roland Roberts")
154 ("Rui-Tao Dong" "Rui-Tao Dong ~{6-Hpln~}")
155 ("Sacha Chua" "Sandra Jean Chua")
156 ("Sam Steingold" "Sam Shteingold")
157 ("Satyaki Das" "Indexed search by Satyaki Das")
158 ("Sébastien Vauban" "Sebastien Vauban")
159 ;; There are other Stefans.
160 ;;; ("Stefan Monnier" "Stefan")
161 ("Stephen A. Wood" "(saw@cebaf.gov)")
162 ("Steven L. Baur" "SL Baur" "Steven L Baur")
163 ("Stewart M. Clamen" "Stewart Clamen")
164 ("Stuart D. Herring" "Stuart Herring" "Davis Herring")
165 ("T.V. Raman" "T\\. V\\. Raman")
166 ("Taichi Kawabata" "KAWABATA,? Taichi")
167 ("Takaaki Ota" "Tak Ota")
168 ("Takahashi Naoto" "Naoto Takahashi")
169 ("Teodor Zlatanov" "Ted Zlatanov")
170 ("Thomas Dye" "Tom Dye")
171 ("Thomas Horsley" "Tom Horsley") ; FIXME ?
172 ("Thomas Wurgler" "Tom Wurgler")
173 ("Toby Cubitt" "Toby S\\. Cubitt")
174 ("Tomohiko Morioka" "MORIOKA Tomohiko")
175 ("Torbjörn Axelsson" "Torbjvrn Axelsson")
176 ("Torbjörn Einarsson" "Torbj.*rn Einarsson")
177 ("Toru Tomabechi" "Toru Tomabechi,")
178 ("Tsugutomo Enami" "enami tsugutomo")
179 ("Ulrich Müller" "Ulrich Mueller")
180 ("Vincent Del Vecchio" "Vince Del Vecchio")
181 ("William M. Perry" "Bill Perry")
182 ("Wlodzimierz Bzyl" "W.*dek Bzyl")
183 ("Yoni Rabkin" "Yoni Rabkin Katzenell")
184 ("Yoshinori Koseki" "KOSEKI Yoshinori" "小関 吉則")
185 ("Yutaka NIIBE" "NIIBE Yutaka")
186 )
187 "Alist of author aliases.
188
189 Each entry is of the form (REALNAME REGEXP...). If an author's name
190 matches one of the REGEXPs, use REALNAME instead.
191 If REALNAME is nil, ignore that author.")
192
193 ;; FIXME seems it would be less fragile to check for O', Mc, etc.
194 (defconst authors-fixed-case
195 '("Bryan O'Sullivan"
196 "Christian von Roques"
197 "Christophe de Dinechin"
198 "Craig McDaniel"
199 "David J. MacKenzie"
200 "David McCabe"
201 "David O'Toole"
202 "Devon Sean McCullough"
203 "Dominique de Waleffe"
204 "Edward O'Connor"
205 "Exal de Jesus Garcia Carrillo"
206 "Greg McGary"
207 "Hans de Graaff"
208 "James TD Smith"
209 "Joel N. Weber II"
210 "Michael McNamara"
211 "Mike McEwan"
212 "Nelson Jose dos Santos Ferreira"
213 "Peter von der Ahe"
214 "Peter O'Gorman"
215 "Piet van Oostrum"
216 "Roland McGrath"
217 "Sean O'Halpin"
218 "Sean O'Rourke"
219 "Tijs van Bakel")
220 "List of authors whose names cannot be simply capitalized.")
221
222 (defvar authors-public-domain-files
223 '("emerge\\.el"
224 "vi\\.el"
225 "feedmail\\.el"
226 "mailpost\\.el"
227 "hanoi\\.el"
228 "meese\\.el"
229 "studly\\.el"
230 "modula2\\.el"
231 "nnmaildir\\.el"
232 "nnil\\.el"
233 "b2m\\.c"
234 "unexhp9k800\\.c"
235 "emacsclient\\.1"
236 "check-doc-strings")
237 "List of regexps matching files for which the FSF doesn't need papers.")
238
239
240 (defvar authors-obsolete-files-regexps
241 '("vc-\\*\\.el$"
242 "spec.txt$"
243 ".*loaddefs.el$" ; not obsolete, but auto-generated
244 "\\.\\(cvs\\|git\\)ignore$" ; obsolete or uninteresting
245 "\\.arch-inventory$"
246 ;; TODO lib/? Matches other things?
247 "build-aux/" "m4/" "Emacs.xcodeproj" "charsets" "mapfiles"
248 "preferences\\.\\(nib\\|gorm\\)"
249 "vc-\\(rcs\\|cvs\\|sccs\\)-hooks\\.el$")
250 "List of regexps matching obsolete files.
251 Changes to files matching one of the regexps in this list are not listed.")
252
253 (defconst authors-ignored-files
254 '("external-lisp"
255 "lock" "share-lib" "local-lisp"
256 "noleim-Makefile.in"
257 "NEWS" "ORDERS" "PROBLEMS" "FAQ" "AUTHORS" "FOR-RELEASE" "TODO" "todo"
258 "MACHINES" "SERVICE"
259 "README.unicode" "README.multi-tty" "TUTORIAL.translators"
260 "NEWS.unicode" "COPYING.DJ" "Makefile.old" "Makefile.am"
261 "NEWS.1" "OOOOONEWS...OONEWS" "OOOONEWS" "etc/NEWS"
262 "NEWS.1-17" "NEWS.18" "NEWS.19" "NEWS.20" "NEWS.21" "NEWS.22"
263 "MAINTAINERS" "MH-E-NEWS"
264 "install-sh" "missing" "mkinstalldirs"
265 "termcap.dat" "termcap.src" "termcap.ucb" "termcap"
266 "ChangeLog.nextstep" "Emacs.clr" "spec.txt"
267 "gfdl.1"
268 "texi/Makefile.in"
269 "Imakefile" "icons/sink.ico" "aixcc.lex"
270 "nxml/char-name/unicode"
271 "js2-mode.el" ; only installed very briefly, replaced by js.el
272 "cedet/tests/testtemplates.cpp"
273 "cedet/tests/testusing.cpp"
274 "cedet/tests/scopetest.cpp"
275 "cedet/tests/scopetest.java"
276 "cedet/tests/test.cpp"
277 "cedet/tests/test.py"
278 "cedet/tests/teststruct.cpp"
279 "*.el"
280 ;; Autogen:
281 "cus-load.el" "finder-inf.el" "ldefs-boot.el"
282 "compile" "config.guess" "config.sub" "depcomp"
283 ;; Only existed briefly, then renamed:
284 "images/icons/allout-widgets-dark-bg"
285 "images/icons/allout-widgets-light-bg"
286 ;; Never had any meaningful changes logged, now deleted:
287 "unidata/bidimirror.awk" "unidata/biditype.awk"
288 "split-man" "Xkeymap.txt" "ms-7bkermit" "ulimit.hack"
289 "gnu-hp300" "refcard.bit" "ledit.l" "forms.README" "forms-d2.dat"
290 "CXTERM-DIC/PY.tit" "CXTERM-DIC/ZIRANMA.tit"
291 "CXTERM-DIC/CTLau.tit" "CXTERM-DIC/CTLauB.tit"
292 "NICKLES.WORTH" "INTERVAL.IDEAS" "RCP"
293 "3B-MAXMEM" "AIX.DUMP" "SUN-SUPPORT" "XENIX"
294 "CODINGS" "CHARSETS"
295 "calc/INSTALL" "calc/Makefile"
296 "vms-pp.trans" "_emacs" "batcomp.com" "notes/cpp" ; admin/
297 "emacsver.texi.in"
298 ;; MH-E stuff not in Emacs:
299 "import-emacs" "release-utils"
300 ;; Erc stuff not in Emacs:
301 "ChangeLog.2001" "ChangeLog.2002" "ChangeLog.2003" "ChangeLog.2004"
302 "ChangeLog.2005"
303 "README.extras" "dir-template" "mkChangeLog" "MkChangeLog" "erc-auto.in"
304 "CREDITS" "HACKING"
305 "debian/changelog"
306 "debian/control"
307 "debian/copyright"
308 "debian/maint/conffiles"
309 "debian/maint/conffiles.in"
310 "debian/maint/postinst"
311 "debian/maint/postinst.in"
312 "debian/maint/prerm"
313 "debian/maint/prerm.in"
314 "debian/README.Debian"
315 "debian/README.erc-speak"
316 "debian/rules"
317 "debian/scripts/install"
318 "debian/scripts/install.in"
319 "debian/scripts/remove"
320 "debian/scripts/remove.in"
321 "debian/scripts/startup"
322 "debian/scripts/startup.erc"
323 "debian/scripts/startup.erc-speak"
324 )
325 "List of files and directories to ignore.
326 Changes to files in this list are not listed.")
327
328 ;; List via: find . -name '*.el' | sed 's/.*\///g' | sort | uniq -d
329 ;; FIXME It would be better to discover these dynamically.
330 ;; Note that traditionally "Makefile.in" etc have not been in this list.
331 ;; Ditto for "abbrev.texi" etc.
332 (defconst authors-ambiguous-files
333 '("chart.el"
334 "compile.el"
335 "complete.el"
336 "cpp.el"
337 "ctxt.el"
338 "custom.el"
339 "cyrillic.el"
340 "czech.el"
341 "debug.el"
342 "dired.el"
343 "el.el"
344 "eshell.el"
345 "ethiopic.el"
346 "f90.el"
347 "files.el"
348 "find.el"
349 "format.el"
350 "generic.el"
351 "georgian.el"
352 "greek.el"
353 "grep.el"
354 "hebrew.el"
355 "imenu.el"
356 "indian.el"
357 "japanese.el"
358 "java.el"
359 "lao.el"
360 "linux.el"
361 "locate.el"
362 "make.el"
363 "mode.el"
364 "python.el"
365 "rmailmm.el"
366 "semantic.el"
367 "shell.el"
368 "simple.el"
369 "slovak.el"
370 "sort.el"
371 "speedbar.el"
372 "srecode.el"
373 "table.el"
374 "texi.el"
375 "thai.el"
376 "tibetan.el"
377 "util.el"
378 "vc-bzr.el"
379 "wisent.el")
380 "List of basenames occurring more than once in the source.")
381
382 ;; FIXME :cowrote entries here can be overwritten by :wrote entries
383 ;; derived from a file's Author: header (eg mh-e). This really means
384 ;; the Author: header is erroneous.
385 (defconst authors-fixed-entries
386 '(("Richard M. Stallman" :wrote "[The original GNU Emacs and numerous files]")
387 ("Joseph Arceneaux" :wrote "xrdb.c")
388 ;; This refers to the obsolete Willisson (qv) version.
389 ;;; ("Blitz Product Development Corporation" :wrote "ispell.el")
390 ("Frank Bresz" :wrote "diff.el")
391 ("David M. Brown" :wrote "array.el")
392 ;; No longer distributed.
393 ;;; ("Gary Byers" :changed "xenix.h")
394 ("Shawn M. Carey" :wrote "freebsd.h")
395 ;; hp800.h renamed from hp9000s800.h, hpux.h merged into hpux10-20.h.
396 ;; FIXME overwritten by Author:.
397 ("Satyaki Das" :cowrote "mh-search.el")
398 ("Eric Decker" :changed "hp800.h" "hpux10-20.h" "sysdep.c")
399 ("Lawrence R. Dodd" :cowrote "dired-x.el")
400 ;; No longer distributed.
401 ;;; ("Viktor Dukhovni" :wrote "unexsunos4.c")
402 ("Paul Eggert" :wrote "rcs2log") ; "vcdiff"
403 ("Fred Fish" :changed "unexcoff.c")
404 ;; No longer distributed.
405 ;;; ("Tim Fleehart" :wrote "makefile.nt")
406 ("Keith Gabryelski" :wrote "hexl.c")
407 ("Kevin Gallagher" :wrote "flow-ctrl.el")
408 ;; Also wrote an earlier version of disp-table.el, since replaced
409 ;; by Erik Naggum's version; also iso-syntax.el, later renamed to
410 ;; latin-1.el, since deleted.
411 ("Howard Gayle" :wrote "casetab.c")
412 ;; :wrote mh-pick.el, since merged into mh-search.el.
413 ;; Originally wrote mh-funcs.el, but it has been rewritten since.
414 ("Stephen Gildea" :wrote "refcard.tex"
415 :cowrote "mh-funcs.el" "mh-search.el")
416 ;; cl.texinfo renamed to cl.texi.
417 ("David Gillespie" :wrote "cl.texi")
418 ;; No longer distributed: emacsserver.c.
419 ("Hewlett-Packard" :changed "emacsclient.c" "server.el" "keyboard.c")
420 ;; No longer distributed.
421 ;;; ("Thomas Horsley" :wrote "cxux.h" "cxux7.h")
422 ("Indiana University Foundation" :changed "buffer.c" "buffer.h"
423 "indent.c" "search.c" "xdisp.c" "region-cache.c" "region-cache.h")
424 ;; ibmrt.h, ibmrt-aix.h no longer distributed.
425 ("International Business Machines" :changed "emacs.c" "fileio.c"
426 "process.c" "sysdep.c" "unexcoff.c")
427 ;; No longer distributed.
428 ;;; ("Ishikawa Chiaki" :changed "aviion.h" "dgux.h")
429 ;; ymakefile no longer distributed.
430 ("Michael K. Johnson" :changed "configure.ac" "emacs.c" "intel386.h"
431 "mem-limits.h" "process.c" "template.h" "sysdep.c" "syssignal.h"
432 "systty.h" "unexcoff.c" "linux.h")
433 ;; No longer distributed.
434 ;;; ("Kyle Jones" :wrote "mldrag.el")
435 ("Henry Kautz" :wrote "bib-mode.el")
436 ;; No longer distributed: vms-pwd.h, vmsfns.c, uaf.h.
437 ("Joseph M. Kelsey" :changed "fileio.c" "dir.h")
438 ("Sam Kendall" :changed "etags.c" "etags.el")
439 ;; ack.texi: "We're not using his backquote.el any more."
440 ("Richard King" :wrote "userlock.el" "filelock.c")
441 ("Sebastian Kremer" :changed "add-log.el")
442 ("Mark Lambert" :changed "process.c" "process.h")
443 ("Aaron Larson" :changed "bibtex.el")
444 ;; It was :wrote, but it has been rewritten since.
445 ("James R. Larus" :cowrote "mh-e.el")
446 ("Lars Lindberg" :changed "dabbrev.el" :cowrote "imenu.el")
447 ;; No longer distributed: lselect.el.
448 ("Lucid, Inc." :changed "bytecode.c" "byte-opt.el" "byte-run.el"
449 "bytecomp.el" "delsel.el" "disass.el" "faces.el" "font-lock.el"
450 "lmenu.el" "mailabbrev.el" "select.el" "xfaces.c" "xselect.c")
451 ;; MCC. No longer distributed: emacsserver.c.
452 ("Microelectronics and Computer Technology Corporation"
453 :changed "etags.c" "emacsclient.c" "movemail.c"
454 "rmail.el" "rmailedit.el" "rmailkwd.el"
455 "rmailmsc.el" "rmailout.el" "rmailsum.el" "scribe.el"
456 ;; It was :wrote for xmenu.c, but it has been rewritten since.
457 "server.el" "lisp.h" "sysdep.c" "unexcoff.c" "xmenu.c")
458 ("Niall Mansfield" :changed "etags.c")
459 ("Brian Marick" :cowrote "hideif.el")
460 ("Marko Kohtala" :changed "info.el")
461 ("Sidney Markowitz" :changed "doctor.el")
462 ;; No longer distributed: env.c.
463 ("Richard Mlynarik" :wrote "ehelp.el")
464 ("Mosur Mohan" :changed "etags.c")
465 ("Jeff Morgenthaler" :changed "flow-ctrl.el" "vt200.el" "vt201.el"
466 "vt220.el" "vt240.el")
467 ("Motorola" :changed "buff-menu.el")
468 ("Hiroshi Nakano" :changed "ralloc.c")
469 ;; File removed in Emacs 24.1.
470 ;;; ("Sundar Narasimhan" :changed "rnewspost.el")
471 ;; No longer distributed.
472 ;;; ("NeXT, Inc." :wrote "unexnext.c")
473 ("Mark Neale" :changed "fortran.el")
474 ;; Renamed from sc.el.
475 ("Martin Neitzel" :changed "supercite.el")
476 ("Andrew Oram" :changed "calendar.texi (and other files in man/)")
477 ("Frederic Pierresteguy" :wrote "widget.c")
478 ("Michael D. Prange" :changed "tex-mode.el")
479 ;; No longer distributed (dgux5-4r3.h was renamed to dgux5-4-3.h).
480 ;;; ("Paul Reilly" :wrote "gux5-4r2.h" "dgux5-4-3.h")
481 ("Roland B. Roberts" :changed "files.el" "sort.el"
482 "buffer.h" "callproc.c" "dired.c" "process.c" "sysdep.c" "systty.h")
483 ;; No longer distributed.
484 ;;; "vmspaths.h" "build.com" "compile.com" "kepteditor.com" "precomp.com"
485 ;;; "vmsproc.el" :wrote "logout.com" "mailemacs.com")
486 ;;; ("Guillermo J. Rozas" :wrote "fakemail.c")
487 ("Wolfgang Rupprecht" :changed "lisp-mode.el" "loadup.el"
488 "sort.el" "alloc.c" "callint.c"
489 ;; config.in renamed from config.h.in; ecrt0.c from crt0.c.
490 "config.in" "ecrt0.c" "data.c" "fns.c"
491 "lisp.h" "lread.c" ; "sun3.h" "ymakefile" - no longer distributed
492 "print.c" :wrote "float-sup.el" "floatfns.c")
493 ("Schlumberger Technology Corporation" :changed "gud.el")
494 ;; Replaced by tcl.el.
495 ;;; ("Gregor Schmid" :wrote "tcl-mode.el")
496 ("Rainer Schoepf" :wrote "alpha.h" "unexalpha.c")
497 ;; No longer distributed: emacsserver.c.
498 ("William Sommerfeld" :wrote "emacsclient.c" "scribe.el")
499 ;; No longer distributed: emacsserver.c.
500 ("Leigh Stoller" :changed "emacsclient.c" "server.el")
501 ("Steve Strassmann" :wrote "spook.el")
502 ("Shinichirou Sugou" :changed "etags.c")
503 ;; No longer distributed: emacsserver.c.
504 ("Sun Microsystems, Inc" :changed "emacsclient.c" "server.el"
505 :wrote "emacs.icon" "sun.el")
506 ;; No longer distributed.
507 ;;; "emacstool.1" "emacstool.c" "sun-curs.el"
508 ;;; "sun-fns.el" "sun-mouse.el" "sunfns.c")
509 ;; Renamed from sc.el.
510 ("Kayvan Sylvan" :changed "supercite.el")
511 ;; No longer distributed: emacsserver.c, tcp.c.
512 ("Spencer Thomas" :changed "emacsclient.c" "server.el"
513 "dabbrev.el" "unexcoff.c" "gnus.texi")
514 ("Jonathan Vail" :changed "vc.el")
515 ("James Van Artsdalen" :changed "usg5-4.h" "unexcoff.c")
516 ;; No longer distributed: src/makefile.nt, lisp/makefile.nt
517 ;; winnt.el renamed to w32-fns.el; nt.[ch] to w32.[ch];
518 ;; ntheap.[ch] to w32heap.[ch]; ntinevt.c to w32inevt.c;
519 ;; ntproc.c to w32proc.c; ntterm.c to w32term.c;
520 ;; windowsnt.h to ms-w32.h.
521 ("Geoff Voelker" :wrote "w32-fns.el" "w32.c" "w32.h" "w32heap.c"
522 "w32heap.h" "w32inevt.c" "w32proc.c" "w32term.c" "ms-w32.h")
523 ("Morten Welinder" :wrote "dosfns.c" "[many MS-DOS files]" "msdos.h")
524 ("Eli Zaretskii" :wrote "bidi.c" "[bidirectional display in xdisp.c]")
525 ;; Not using this version any more.
526 ;;; ("Pace Willisson" :wrote "ispell.el")
527 ;; FIXME overwritten by Author:.
528 ("Bill Wohler" :cowrote "mh-e.el")
529 ("Garrett Wollman" :changed "sendmail.el")
530 ("Dale R. Worley" :changed "mail-extr.el")
531 ("Jamie Zawinski" :changed "bytecode.c" :wrote "tar-mode.el"
532 :cowrote "disass.el"))
533 "Actions taken from the original, manually (un)maintained AUTHORS file.")
534
535
536 (defconst authors-valid-file-names
537 '("aclocal.m4"
538 "build-ins.in"
539 "Makefile.noleim"
540 "makedist.bat"
541 "makefile.def"
542 "makefile.nt"
543 "debug.bat.in" "emacs.bat.in"
544 ".gdbinit-union"
545 "alloca.s"
546 "make-delta"
547 "config.w95"
548 "emacstool.1"
549 "align.umax"
550 "cxux-crt0.s"
551 "gould-sigvec.s"
552 "getdate.y"
553 "ymakefile"
554 "permute-index" "index.perm"
555 "ibmrs6000.inp"
556 "b2m.c" "b2m.1" "b2m.pl"
557 "emacs.bash" "emacs.csh" "ms-kermit"
558 "emacs.ico"
559 "emacs21.ico"
560 "BABYL" "LPF" "LEDIT" "OTHER.EMACSES"
561 "emacs16_mac.png" "emacs24_mac.png"
562 "emacs256_mac.png" "emacs32_mac.png"
563 "emacs48_mac.png" "emacs512_mac.png"
564 "revdiff" ; admin/
565 "mainmake" "sed1.inp" "sed2.inp" "sed3.inp" ; msdos/
566 "mac-fix-env.m"
567 ;; Deleted vms stuff:
568 "temacs.opt" "descrip.mms" "compile.com" "link.com"
569 )
570 "File names which are valid, but no longer exist (or cannot be found)
571 in the repository.")
572
573 (defconst authors-renamed-files-alist
574 '(("nt.c" . "w32.c") ("nt.h" . "w32.h")
575 ("ntheap.c" . "w32heap.c") ("ntheap.h" . "w32heap.h")
576 ("ntinevt.c" . "w32inevt.c") ("ntinevt.h" . "w32inevt.h")
577 ("ntproc.c" . "w32proc.c")
578 ("w32console.c" . "w32term.c")
579 ("unexnt.c" . "unexw32.c")
580 ("s/windowsnt.h" . "s/ms-w32.h")
581 ("s/ms-w32.h" . "inc/ms-w32.h")
582 ("winnt.el" . "w32-fns.el")
583 ("config.emacs" . "configure")
584 ("configure.in" . "configure.ac")
585 ("config.h.dist" . "config.in")
586 ("config.h-dist" . "config.in")
587 ("config.h.in" . "config.in")
588 ("paths.h-dist" . "paths.h.in")
589 ("patch1" . "sed1.inp")
590 ("GETTING.GNU.SOFTWARE" . "FTP")
591 ("etc/MACHINES" . "MACHINES")
592 ("ONEWS" . "NEWS.19")
593 ("ONEWS.1" . "NEWS.1-17")
594 ("ONEWS.2" . "NEWS.1-17")
595 ("ONEWS.3" . "NEWS.18")
596 ("ONEWS.4" . "NEWS.18")
597 ("ORDERS.USA" . "ORDERS")
598 ("EUROPE" . "ORDERS")
599 ("DIFF" . "OTHER.EMACSES")
600 ("CCADIFF" . "OTHER.EMACSES")
601 ("GOSDIFF" . "OTHER.EMACSES")
602 ("Makefile.in.in" . "Makefile.in")
603 ("leim-Makefile" . "leim/Makefile")
604 ("leim-Makefile.in" . "leim/Makefile.in")
605 ("emacs-lisp/testcover-ses.el" . "tcover-ses.el")
606 ("emacs-lisp/testcover-unsafep.el" . "tcover-unsafep.el")
607 ;; index and pick merged into search.
608 ("mh-index.el" . "mh-search.el")
609 ("mh-pick.el" . "mh-search.el")
610 ("font-setting.el" . "dynamic-setting.el")
611 ;; INSTALL-CVS -> .CVS -> .BZR
612 ("INSTALL-CVS" . "INSTALL.BZR")
613 ("INSTALL.CVS" . "INSTALL.BZR")
614 ("refcards/fr-drdref.pdf" . "refcards/fr-dired-ref.pdf")
615 ("gnus-logo.eps" . "refcards/gnus-logo.eps")
616 ("build-install" . "build-ins.in")
617 ("build-install.in" . "build-ins.in")
618 ("unidata/Makefile" . "unidata/Makefile.in")
619 ;; Not renamed, but we only have the latter in the Emacs repo.
620 ("trampver.texi.in" . "trampver.texi")
621 ("e/eterm" . "e/eterm-color")
622 ("e/eterm.ti" . "e/eterm-color.ti")
623 ("README.txt" . "README")
624 ("emacs.names" . "JOKES")
625 ("ED.WORSHIP" . "JOKES")
626 ("GNU.JOKES" . "JOKES")
627 ("CHARACTERS" . "TODO")
628 ("schema/xhtml-basic-form.rnc" . "schema/xhtml-bform.rnc" )
629 ("schema/xhtml-basic-table.rnc" . "schema/xhtml-btable.rnc")
630 ("schema/xhtml-list.rnc" . "schema/xhtml-lst.rnc")
631 ("schema/xhtml-target.rnc" . "schema/xhtml-tgt.rnc")
632 ("schema/xhtml-style.rnc" . "schema/xhtml-xstyle.rnc")
633 ("schema/docbook-dyntbl.rnc" . "schema/docbk-dyntbl.rnc")
634 ("schema/docbook-soextbl.rnc" . "schema/docbk-soextbl.rn" )
635 ("texi/url.txi" . "url.texi")
636 ("edt-user.doc" . "edt.texi")
637 ("DEV-NOTES" . "nextstep")
638 ("org/COPYRIGHT-AND-LICENSE" . "org/README")
639 ;; Moved to different directories.
640 ("ctags.1" . "ctags.1")
641 ("etags.1" . "etags.1")
642 ("emacs.1" . "emacs.1")
643 ("emacsclient.1" . "emacsclient.1")
644 ("icons/emacs21.ico" . "emacs21.ico")
645 ;; Moved from admin/nt/ to nt/.
646 ("nt/README.W32" . "README.W32")
647 )
648 "Alist of files which have been renamed during their lifetime.
649 Elements are (OLDNAME . NEWNAME).")
650
651 (defconst authors-renamed-files-regexps
652 '(("^m/m-\\(.*\\.h\\)$" . "m/\\1")
653 ("^m-\\(.*\\.h\\)$" . "\\1")
654 ("^s/s-\\(.*\\.h\\)$" . "s/\\1")
655 ("^s-\\(.*\\.h\\)$" . "\\1")
656 ("^s/[-.a-zA-Z0-9_]+\\.h$" . t)
657 ("\\(.*\\)\\.cmd$" . "\\1.bat")
658 ("\\.bat$" . t)
659 ("\\.[ch]$" . t)
660 ("\\.el$" . t)
661 ("\\.ps$" . t)
662 ("\\.texi?$" . t)
663 ("\\.texinfo$" . t)
664 ("\\.xml?$" . t)
665 ("\\.x[pb]m$" . t)
666 ("\\.[xp]bm$" . t)
667 ("^paths\\." . t)
668 ("^install\\." . t)
669 ("^\\(TUTORIAL[^/]*\\)" . "tutorials/\\1")
670 ("^\\(tree-widget/\\(?:default\\|folder\\)/[-a-z]+\\.png\\)$" .
671 "images/\\1")
672 ("^\\(images/icons/\\)mac\\(emacs\\)_\\([0-9]+\\)\\(\\.png\\)" .
673 "\\1\\2\\3_mac\\4")
674 ("\\(images/icons/\\)emacs_\\([0-9][0-9]\\)\\.png" .
675 "\\1hicolor/\\2x\\2/apps/emacs.png")
676 )
677 "List regexps and rewriting rules for renamed files.
678 Elements are (REGEXP . REPLACE). If REPLACE is a string, the file
679 name matching REGEXP is replaced by REPLACE using `replace-string'.
680 Otherwise, the file name is accepted as is.")
681
682 (defvar authors-checked-files-alist)
683 (defvar authors-invalid-file-names)
684
685 (defun authors-disambiguate-file-name (fullname)
686 "Convert FULLNAME to an unambiguous relative-name."
687 (let ((relname (file-name-nondirectory fullname))
688 parent)
689 (if (member relname authors-ambiguous-files)
690 ;; In case of ambiguity, just prepend the parent directory.
691 ;; FIXME obviously this is not a perfect solution.
692 (if (string-equal "lisp"
693 (setq parent (file-name-nondirectory
694 (directory-file-name
695 (file-name-directory fullname)))))
696 relname
697 (format "%s/%s" parent relname))
698 relname)))
699
700 (defun authors-canonical-file-name (file log-file pos author)
701 "Return canonical file name for FILE found in LOG-FILE.
702 Checks whether FILE is a valid (existing) file name, has been renamed,
703 or is on the list of removed files. Returns the non-directory part of
704 the file name. Only uses the LOG-FILE position POS and associated AUTHOR
705 to print a message if FILE is not found."
706 ;; FILE should be re-checked in every different directory associated
707 ;; with a LOG-FILE. Eg configure.ac from src/ChangeLog is not the
708 ;; same as that from top-level/ChangeLog.
709 (let* ((fullname (expand-file-name file (file-name-directory log-file)))
710 (entry (assoc fullname authors-checked-files-alist))
711 relname
712 valid)
713 (if entry
714 (cdr entry)
715 (setq relname (file-name-nondirectory file))
716 (if (or (member relname authors-valid-file-names)
717 (file-exists-p file)
718 (file-exists-p relname)
719 (file-exists-p (concat "etc/" relname)))
720 (setq valid (authors-disambiguate-file-name fullname))
721 (setq valid (assoc file authors-renamed-files-alist))
722 (if valid
723 (setq valid (cdr valid))
724 (let ((rules authors-renamed-files-regexps))
725 (while rules
726 (if (string-match (car (car rules)) file)
727 (setq valid (if (stringp (cdr (car rules)))
728 (file-name-nondirectory
729 (replace-match (cdr (car rules)) t nil file))
730 relname)
731 rules nil))
732 (setq rules (cdr rules))))))
733 (setq authors-checked-files-alist
734 (cons (cons fullname valid) authors-checked-files-alist))
735 (unless (or valid
736 (member file authors-ignored-files)
737 (authors-obsolete-file-p file)
738 (string-match "[*]" file)
739 (string-match "^[0-9.]+$" file))
740 (setq authors-invalid-file-names
741 (cons (format "%s:%d: unrecognized `%s' for %s"
742 log-file
743 (1+ (count-lines (point-min) pos))
744 file author)
745 authors-invalid-file-names)))
746 valid)))
747
748 (defun authors-add-fixed-entries (table)
749 "Add actions from `authors-fixed-entries' to TABLE."
750 (dolist (entry authors-fixed-entries)
751 (let ((author (car entry))
752 action)
753 (dolist (item (cdr entry))
754 (if (symbolp item)
755 (setq action item)
756 (authors-add author item action table))))))
757
758
759 (defun authors-obsolete-file-p (file)
760 "Return non-nil if FILE is obsolete.
761 FILE is considered obsolete if it matches one of the regular expressions
762 from `authors-obsolete-files-regexps'."
763 (let (obsolete-p
764 (regexps authors-obsolete-files-regexps))
765 (while (and regexps (not obsolete-p))
766 (setq obsolete-p (string-match (car regexps) file)
767 regexps (cdr regexps)))
768 obsolete-p))
769
770
771 (defun authors-add (author file action table)
772 "Record that AUTHOR worked on FILE.
773 ACTION is a keyword symbol describing what he did. Record file,
774 author and what he did in hash table TABLE. See the description of
775 `authors-scan-change-log' for the structure of the hash table."
776 (unless (or (member file authors-ignored-files)
777 (authors-obsolete-file-p file)
778 (equal author ""))
779 (let* ((value (gethash author table))
780 (entry (assoc file value))
781 slot)
782 (if (null entry)
783 (puthash author (cons (list file (cons action 1)) value) table)
784 (if (setq slot (assoc action (cdr entry)))
785 (setcdr slot (1+ (cdr slot)))
786 (nconc entry (list (cons action 1))))))))
787
788
789 (defun authors-canonical-author-name (author)
790 "Return a canonicalized form of AUTHOR, an author name.
791 If AUTHOR has an entry in `authors-aliases', use that. Remove
792 email addresses. Capitalize words in the author's name, unless
793 it is found in `authors-fixed-case'."
794 (let* ((aliases authors-aliases)
795 regexps realname)
796 (while aliases
797 (setq realname (car (car aliases))
798 regexps (cdr (car aliases))
799 aliases (cdr aliases))
800 (while regexps
801 (if (string-match (car regexps) author)
802 (setq author realname
803 regexps nil
804 aliases nil)
805 (setq regexps (cdr regexps))))))
806 (when author
807 (setq author (replace-regexp-in-string "[ \t]*[(<].*$" "" author))
808 (setq author (replace-regexp-in-string "\`[ \t]+" "" author))
809 (setq author (replace-regexp-in-string "[ \t]+$" "" author))
810 (setq author (replace-regexp-in-string "[ \t]+" " " author))
811 (unless (string-match "[-, \t]" author)
812 (setq author ""))
813 (or (car (member author authors-fixed-case))
814 (capitalize author))))
815
816 (defun authors-scan-change-log (log-file table)
817 "Scan change log LOG-FILE for author information.
818
819 For each change mentioned in the log, add an entry to hash table TABLE
820 under the author's canonical name.
821
822 Keys of TABLE are author names. Values are alists of entries (FILE
823 \(ACTION . COUNT) ...). FILE is one file the author worked on. The
824 rest of the entry is a list of keyword symbols describing what he did
825 with the file and the number of each action:
826
827 :wrote means the author wrote the file
828 :cowrote means he wrote the file in collaboration with others
829 :changed means he changed the file COUNT times."
830
831 (let* ((enable-local-variables :safe) ; for find-file, hence let*
832 (enable-local-eval nil)
833 (existing-buffer (get-file-buffer log-file))
834 (buffer (find-file-noselect log-file))
835 authors pos)
836 (with-current-buffer buffer
837 (save-restriction
838 (widen)
839 (goto-char (point-min))
840 (while (re-search-forward "^[0-9]\\|^[ \t]+\\* " nil t)
841 (beginning-of-line)
842 (setq pos (point))
843 (cond ((looking-at "^[0-9]+-[0-9]+-[0-9]+")
844 ;; Handle joint authorship of changes.
845 ;; This can be a bit fragile, and is not too common.
846 (setq authors nil)
847 (while (progn
848 (skip-chars-forward " \t+:0-9-")
849 (not (looking-at "\\($\\|\\*\\|\
850 Suggested\\|Trivial\\|Version\\|Originally\\|From:\\|Patch[ \t]+[Bb]y\\)")))
851 (push (authors-canonical-author-name
852 (buffer-substring-no-properties
853 (point) (line-end-position))) authors)
854 (forward-line 1)))
855 ((looking-at "^[ \t]+\\*")
856 (let ((line (buffer-substring-no-properties
857 (match-end 0) (line-end-position))))
858 (while (and (not (string-match ":" line))
859 (forward-line 1)
860 (not (looking-at ":\\|^[ \t]*$")))
861 (setq line (concat line
862 (buffer-substring-no-properties
863 (line-beginning-position)
864 (line-end-position)))))
865 (when (string-match ":" line)
866 (setq line (substring line 0 (match-beginning 0)))
867 (setq line (replace-regexp-in-string "[[(<{].*$" "" line))
868 (setq line (replace-regexp-in-string "," "" line))
869 (dolist (file (split-string line))
870 (when (setq file (authors-canonical-file-name file log-file pos (car authors)))
871 (dolist (author authors)
872 ;;(message "%s changed %s" author file)
873 (authors-add author file :changed table)))))
874 (forward-line 1)))))))
875 (unless existing-buffer
876 (kill-buffer buffer))))
877
878
879 (defun authors-scan-el (file table)
880 "Scan Lisp file FILE for author information.
881 TABLE is a hash table to add author information to."
882 (let* ((existing-buffer (get-file-buffer file))
883 (enable-local-variables :safe) ; for find-file, hence let*
884 (enable-local-eval nil)
885 (buffer (find-file-noselect file)))
886 (setq file (authors-disambiguate-file-name (expand-file-name file)))
887 (with-current-buffer buffer
888 (save-restriction
889 (widen)
890 (goto-char (point-min))
891 (while (and (re-search-forward
892 "^;+[ \t]*\\(Authors?\\|Commentary\\|Code\\):[ \t]*" nil t)
893 (not (member (match-string 1) '("Commentary" "Code"))))
894 (let ((continue t)
895 (action :wrote)
896 authors)
897 (while continue
898 ;; Some entries contain a year range in front of the
899 ;; author's name.
900 (skip-chars-forward "-0-9 \t")
901 (push (authors-canonical-author-name
902 (buffer-substring-no-properties
903 (point) (line-end-position))) authors)
904 ;; tips.texi says the continuation line should begin
905 ;; with a tab, but often spaces are used.
906 (setq continue
907 (and (zerop (forward-line 1))
908 (looking-at ";;;?\\(\t+ *\\| +\\)[[:alnum:]]")
909 (goto-char (1- (match-end 0)))
910 (not (looking-at "[[:upper:]][-[:alpha:]]+:[ \t]")))))
911 (and (> (length authors) 1)
912 (setq action :cowrote))
913 (mapc (lambda (author)
914 (authors-add author file action table))
915 authors)))))
916 (unless existing-buffer
917 (kill-buffer buffer))))
918
919
920 (defun authors-public-domain-p (file)
921 "Return t if FILE is a file that was put in public domain."
922 (let ((public-domain-p nil)
923 (list authors-public-domain-files))
924 (while (and list (not public-domain-p))
925 (when (string-match (car list) file)
926 (setq public-domain-p t))
927 (setq list (cdr list)))
928 public-domain-p))
929
930 (defvar authors-author-list)
931
932 (defun authors-add-to-author-list (author changes)
933 "Insert information about AUTHOR's work on Emacs into `authors-author-list'.
934 CHANGES is an alist of entries (FILE (ACTION . COUNT) ...), as produced by
935 `authors-scan-change-log'.
936 The element added to `authors-author-list' is (AUTHOR WROTE CO-WROTE CHANGED),
937 where WROTE, CO-WROTE, and CHANGED are lists of the files written, co-written
938 and changed by AUTHOR."
939 (when author
940 (let ((nchanged 0)
941 wrote-list
942 cowrote-list
943 changed-list)
944 (dolist (change changes)
945 (let* ((actions (cdr change))
946 (file (car change))
947 (filestat (if (authors-public-domain-p file)
948 (concat file " (public domain)")
949 file)))
950 (cond ((assq :wrote actions)
951 (setq wrote-list (cons filestat wrote-list)))
952 ((assq :cowrote actions)
953 (setq cowrote-list (cons filestat cowrote-list)))
954 (t
955 (setq changed-list
956 (cons (cons file (cdr (assq :changed actions)))
957 changed-list))))))
958 (if wrote-list
959 (setq wrote-list (sort wrote-list 'string-lessp)))
960 (if cowrote-list
961 (setq cowrote-list (sort cowrote-list 'string-lessp)))
962 (when changed-list
963 (setq changed-list (sort changed-list
964 (lambda (a b)
965 (if (= (cdr a) (cdr b))
966 (string-lessp (car a) (car b))
967 (> (cdr a) (cdr b))))))
968 (setq nchanged (length changed-list))
969 (setq changed-list (mapcar 'car changed-list)))
970 (if (> (- nchanged authors-many-files) 2)
971 (setcdr (nthcdr authors-many-files changed-list)
972 (list (format "and %d other files" (- nchanged authors-many-files)))))
973 (setq authors-author-list
974 (cons (list author wrote-list cowrote-list changed-list)
975 authors-author-list)))))
976
977 (defun authors (root)
978 "Extract author information from change logs and Lisp source files.
979 ROOT is the root directory under which to find the files. If called
980 interactively, ROOT is read from the minibuffer.
981 Result is a buffer *Authors* containing authorship information, and a
982 buffer *Authors Errors* containing references to unknown files."
983 (interactive "DEmacs source directory: ")
984 (setq root (expand-file-name root))
985 (let ((logs (process-lines find-program root "-name" "ChangeLog*"))
986 (table (make-hash-table :test 'equal))
987 (buffer-name "*Authors*")
988 authors-checked-files-alist
989 authors-invalid-file-names)
990 (authors-add-fixed-entries table)
991 (unless (file-exists-p (expand-file-name "src/emacs.c" root))
992 (unless (y-or-n-p
993 (format "Not the root directory of Emacs: %s, continue? " root))
994 (error "Not the root directory")))
995 (dolist (log logs)
996 (when (string-match "ChangeLog\\(.[0-9]+\\)?$" log)
997 (message "Scanning %s..." log)
998 (authors-scan-change-log log table)))
999 (let ((els (process-lines find-program root "-name" "*.el")))
1000 (dolist (file els)
1001 (message "Scanning %s..." file)
1002 (authors-scan-el file table)))
1003 (message "Generating buffer %s..." buffer-name)
1004 (set-buffer (get-buffer-create buffer-name))
1005 (erase-buffer)
1006 (set-buffer-file-coding-system authors-coding-system)
1007 (insert
1008 "Many people have contributed code included in the Free Software
1009 Foundation's distribution of GNU Emacs. To show our appreciation for
1010 their public spirit, we list here in alphabetical order a condensed
1011 list of their contributions.\n")
1012 (let (authors-author-list a)
1013 (maphash #'authors-add-to-author-list table)
1014 (setq authors-author-list
1015 (sort authors-author-list
1016 (lambda (a b) (string-lessp (car a) (car b)))))
1017 (dolist (a authors-author-list)
1018 (let ((author (car a))
1019 (wrote (nth 1 a))
1020 (cowrote (nth 2 a))
1021 (changed (nth 3 a))
1022 file)
1023 (insert "\n" author ": ")
1024 (when wrote
1025 (insert "wrote")
1026 (dolist (file wrote)
1027 (if (> (+ (current-column) (length file)) 72)
1028 (insert "\n "))
1029 (insert " " file))
1030 (insert "\n"))
1031 (when cowrote
1032 (if wrote
1033 (insert "and "))
1034 (insert "co-wrote")
1035 (dolist (file cowrote)
1036 (if (> (+ (current-column) (length file)) 72)
1037 (insert "\n "))
1038 (insert " " file))
1039 (insert "\n"))
1040 (when changed
1041 (if (or wrote cowrote)
1042 (insert "and "))
1043 (insert "changed")
1044 (dolist (file changed)
1045 (if (> (+ (current-column) (length file)) 72)
1046 (insert "\n "))
1047 (insert " " file))
1048 (insert "\n")))))
1049 (insert "\nLocal" " Variables:\ncoding: "
1050 (symbol-name authors-coding-system) "\nEnd:\n")
1051 (message "Generating buffer %s... done" buffer-name)
1052 (unless noninteractive
1053 (when authors-invalid-file-names
1054 (with-current-buffer (get-buffer-create "*Authors Errors*")
1055 (setq buffer-read-only nil)
1056 (erase-buffer)
1057 (set-buffer-file-coding-system authors-coding-system)
1058 (insert "Unrecognized file entries found:\n\n")
1059 (mapc (lambda (f) (if (not (string-match "^[A-Za-z]+$" f)) (insert f "\n")))
1060 (sort authors-invalid-file-names 'string-lessp))
1061 (goto-char (point-min))
1062 (compilation-mode)
1063 (message "Errors were found. See buffer %s" (buffer-name))))
1064 (pop-to-buffer buffer-name))))
1065
1066
1067 (defun batch-update-authors ()
1068 "Produce an AUTHORS file.
1069 Call this function in batch mode with two command line arguments FILE
1070 and ROOT. FILE is the file to write, ROOT is the root directory of
1071 the Emacs source tree, from which to build the file."
1072 (unless noninteractive
1073 (error "`batch-update-authors' is to be used only with -batch"))
1074 (when (/= (length command-line-args-left) 2)
1075 (error "Call `batch-update-authors' with the name of the file to write"))
1076 (let* ((file (pop command-line-args-left))
1077 (root (pop command-line-args-left)))
1078 (authors root)
1079 (write-file file)))
1080
1081 (provide 'authors)
1082
1083 ;;; authors.el ends here