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