Mercurial > emacs
view admin/admin.el @ 105813:df4934f25eef
* textmodes/two-column.el (2C-split):
* textmodes/texnfo-upd.el (texinfo-multi-file-included-list):
* textmodes/tex-mode.el (tex-set-buffer-directory):
* textmodes/spell.el (spell-region, spell-string):
* textmodes/reftex.el (reftex-erase-buffer):
(reftex-get-file-buffer-force, reftex-kill-temporary-buffers):
* textmodes/reftex-toc.el (reftex-toc-promote-action):
* textmodes/reftex-sel.el (reftex-get-offset, reftex-insert-docstruct)
(reftex-select-item):
* textmodes/reftex-ref.el (reftex-label-info-update)
(reftex-offer-label-menu):
* textmodes/reftex-index.el (reftex-index-change-entry)
(reftex-index-phrases-info):
* textmodes/reftex-global.el (reftex-create-tags-file)
(reftex-save-all-document-buffers, reftex-ensure-write-access):
* textmodes/reftex-dcr.el (reftex-echo-ref, reftex-echo-cite)
(reftex-view-crossref-from-bibtex):
* textmodes/reftex-cite.el (reftex-bibtex-selection-callback)
(reftex-extract-bib-entries-from-thebibliography)
(reftex-all-used-citation-keys, reftex-create-bibtex-file):
* textmodes/refbib.el (r2b-capitalize-title):
(r2b-convert-buffer, r2b-help):
* textmodes/page-ext.el (pages-directory)
(pages-directory-goto-with-mouse):
* textmodes/bibtex.el (bibtex-validate-globally):
* textmodes/bib-mode.el (bib-capitalize-title):
* textmodes/artist.el (artist-clear-buffer, artist-system):
* progmodes/xscheme.el (global-set-scheme-interaction-buffer):
(local-set-scheme-interaction-buffer, xscheme-process-filter)
(verify-xscheme-buffer, xscheme-enter-interaction-mode)
(xscheme-enter-debugger-mode, xscheme-debugger-mode-p)
(xscheme-send-control-g-interrupt, xscheme-start-process)
(xscheme-process-sentinel, xscheme-cd):
* progmodes/verilog-mode.el (verilog-read-always-signals)
(verilog-set-define, verilog-getopt-file)
(verilog-module-inside-filename-p):
* progmodes/sh-script.el:
* progmodes/python.el (python-pdbtrack-get-source-buffer)
(python-pdbtrack-grub-for-buffer, python-execute-file):
* progmodes/octave-inf.el (inferior-octave):
* progmodes/idlwave.el (idlwave-scan-user-lib-files)
(idlwave-shell-compile-helper-routines, idlwave-set-local)
(idlwave-display-completion-list-xemacs, idlwave-list-abbrevs)
(idlwave-display-completion-list-emacs, idlwave-list-load-path-shadows)
(idlwave-completion-fontify-classes, idlwave-display-calling-sequence):
* progmodes/idlw-shell.el (idlwave-shell-examine-display-clear)
(idlwave-shell-filter, idlwave-shell-examine-highlight)
(idlwave-shell-sentinel, idlwave-shell-filter-directory)
(idlwave-shell-display-line, idlwave-shell-set-bp-in-module)
(idlwave-shell-examine-display, idlwave-shell-run-region)
(idlwave-shell-filter-bp, idlwave-shell-save-and-action)
(idlwave-shell-sources-filter, idlwave-shell-goto-next-error):
* progmodes/idlw-help.el (idlwave-help-get-special-help)
(idlwave-help-get-help-buffer):
* progmodes/gud.el (gud-basic-call, gud-find-class)
(gud-tooltip-activate-mouse-motions-if-enabled):
* progmodes/gdb-mi.el (gdb-mouse-toggle-breakpoint-fringe):
* progmodes/ebrowse.el (ebrowse-member-table, ebrowse-save-tree-as)
(ebrowse-view-exit-fn, ebrowse-tags-list-members-in-file)
(ebrowse-tags-next-file):
* progmodes/ebnf2ps.el (ebnf-generate-eps, ebnf-generate-eps)
(ebnf-eps-production-list, ebnf-begin-file, ebnf-log)
(ebnf-eps-finish-and-write):
* progmodes/cpp.el (cpp-edit-save):
* progmodes/cperl-mode.el (cperl-pod-to-manpage):
* progmodes/cc-defs.el (c-emacs-features):
* progmodes/antlr-mode.el (antlr-invalidate-context-cache)
(antlr-directory-dependencies):
* progmodes/ada-xref.el (ada-gnat-parse-gpr, ada-get-ali-file-name)
(ada-run-application, ada-find-in-src-path, ada-goto-parent)
(ada-find-any-references, ada-make-filename-from-adaname)
(ada-make-body-gnatstub):
* obsolete/rnews.el (news-list-news-groups):
* obsolete/resume.el (resume-suspend-hook,resume-write-buffer-to-file):
* obsolete/iso-acc.el (iso-acc-minibuf-setup):
* net/rcirc.el (rcirc-debug):
* net/newst-treeview.el (newsticker--treeview-list-add-item)
(newsticker--treeview-list-clear, newsticker-treeview-browse-url)
(newsticker--treeview-list-update-faces, newsticker-treeview-save)
(newsticker--treeview-item-show-text, newsticker--treeview-item-show)
(newsticker--treeview-tree-update-tag,newsticker--treeview-buffer-init)
(newsticker-treeview-show-item, newsticker--treeview-unfold-node)
(newsticker--treeview-list-clear-highlight)
(newsticker--treeview-list-update-highlight)
(newsticker--treeview-list-highlight-start)
(newsticker--treeview-tree-update-highlight)
(newsticker--treeview-get-selected-item)
(newsticker-treeview-mark-list-items-old)
(newsticker--treeview-set-current-node):
* net/newst-plainview.el (newsticker--buffer-set-uptodate):
* net/newst-backend.el (newsticker--get-news-by-funcall)
(newsticker--get-news-by-wget, newsticker--image-get)
(newsticker--image-sentinel):
* net/mairix.el (mairix-rmail-fetch-field, mairix-gnus-fetch-field):
* net/eudcb-ph.el (eudc-ph-do-request, eudc-ph-open-session):
(eudc-ph-close-session):
* net/eudc.el (eudc-save-options):
* language/thai-word.el (thai-update-word-table):
* language/japan-util.el (japanese-string-conversion):
* international/titdic-cnv.el (tsang-quick-converter)
(ziranma-converter, ctlau-converter):
* international/mule-cmds.el (describe-language-environment):
* international/ja-dic-cnv.el (skkdic-convert-okuri-ari)
(skkdic-convert-postfix, skkdic-convert-prefix):
(skkdic-convert-okuri-nasi, skkdic-convert):
* emacs-lisp/re-builder.el (reb-update-overlays):
* emacs-lisp/pp.el (pp-to-string, pp-display-expression):
* emacs-lisp/gulp.el (gulp-send-requests):
* emacs-lisp/find-gc.el (trace-call-tree):
* emacs-lisp/eieio-opt.el (eieio-browse, eieio-describe-class)
(eieio-describe-generic):
* emacs-lisp/eieio-base.el (eieio-persistent-read):
* emacs-lisp/edebug.el (edebug-outside-excursion):
* emacs-lisp/debug.el (debugger-make-xrefs):
* emacs-lisp/cust-print.el (custom-prin1-to-string):
* emacs-lisp/chart.el (chart-new-buffer):
* emacs-lisp/authors.el (authors-scan-el, authors-scan-change-log):
Use with-current-buffer.
* textmodes/artist.el (artist-system): Don't call
copy-sequence on a fresh string.
* progmodes/idlw-shell.el (easymenu setup): Use dolist.
author | Stefan Monnier <monnier@iro.umontreal.ca> |
---|---|
date | Sat, 31 Oct 2009 02:38:34 +0000 |
parents | 37e835e25528 |
children | 1d1d5d9bd884 |
line wrap: on
line source
;;; admin.el --- utilities for Emacs administration ;; Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009 ;; Free Software Foundation, Inc. ;; This file is part of GNU Emacs. ;; GNU Emacs is free software: you can redistribute it and/or modify ;; it under the terms of the GNU General Public License as published by ;; the Free Software Foundation, either version 3 of the License, or ;; (at your option) any later version. ;; GNU Emacs is distributed in the hope that it will be useful, ;; but WITHOUT ANY WARRANTY; without even the implied warranty of ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ;; GNU General Public License for more details. ;; You should have received a copy of the GNU General Public License ;; along with GNU Emacs. If not, see <http://www.gnu.org/licenses/>. ;;; Commentary: ;; add-release-logs Add ``Version X released'' change log entries. ;; set-version Change Emacs version number in source tree. ;; set-copyright Change emacs short copyright string (eg as ;; printed by --version) in source tree. ;;; Code: (defun add-release-logs (root version) "Add \"Version VERSION released.\" change log entries in ROOT. Root must be the root of an Emacs source tree." (interactive "DEmacs root directory: \nNVersion number: ") (setq root (expand-file-name root)) (unless (file-exists-p (expand-file-name "src/emacs.c" root)) (error "%s doesn't seem to be the root of an Emacs source tree" root)) (require 'add-log) (let* ((logs (process-lines "find" root "-name" "ChangeLog")) (entry (format "%s %s <%s>\n\n\t* Version %s released.\n\n" (funcall add-log-time-format) (or add-log-full-name (user-full-name)) (or add-log-mailing-address user-mail-address) version))) (dolist (log logs) (unless (string-match "/gnus/" log) (find-file log) (goto-char (point-min)) (insert entry))))) (defun set-version-in-file (root file version rx) (find-file (expand-file-name file root)) (goto-char (point-min)) (unless (re-search-forward rx nil t) (error "Version not found in %s" file)) (replace-match (format "%s" version) nil nil nil 1)) (defun set-version (root version) "Set Emacs version to VERSION in relevant files under ROOT. Root must be the root of an Emacs source tree." (interactive "DEmacs root directory: \nsVersion number: ") (unless (file-exists-p (expand-file-name "src/emacs.c" root)) (error "%s doesn't seem to be the root of an Emacs source tree" root)) (set-version-in-file root "lisp/version.el" version (rx (and "emacs-version" (0+ space) ?\" (submatch (1+ (not (in ?\")))) ?\"))) (set-version-in-file root "README" version (rx (and "version" (1+ space) (submatch (1+ (in "0-9.")))))) (set-version-in-file root "configure.in" version (rx (and "AC_INIT" (1+ (not (in ?,))) ?, (0+ space) (submatch (1+ (in "0-9.")))))) (set-version-in-file root "doc/emacs/emacs.texi" version (rx (and "EMACSVER" (1+ space) (submatch (1+ (in "0-9.")))))) (set-version-in-file root "doc/lispref/elisp.texi" version (rx (and "EMACSVER" (1+ space) (submatch (1+ (in "0-9.")))))) (set-version-in-file root "doc/lispref/vol1.texi" version (rx (and "EMACSVER" (1+ space) (submatch (1+ (in "0-9.")))))) (set-version-in-file root "doc/lispref/vol2.texi" version (rx (and "EMACSVER" (1+ space) (submatch (1+ (in "0-9.")))))) (set-version-in-file root "doc/lispref/book-spine.texinfo" version (rx (and "Emacs Version" (1+ space) (submatch (1+ (in "0-9.")))))) (set-version-in-file root "doc/man/emacs.1" version (rx (and ".TH EMACS" (1+ not-newline) "GNU Emacs" (1+ space) (submatch (1+ (in "0-9.")))))) (set-version-in-file root "doc/misc/faq.texi" version (rx (and "VER" (1+ space) (submatch (1+ (in "0-9.")))))) (set-version-in-file root "lib-src/makefile.w32-in" version (rx (and "VERSION" (0+ space) "=" (0+ space) (submatch (1+ (in "0-9.")))))) ;; nt/emacs.rc also contains the version number, but in an awkward ;; format. It must contain four components, separated by commas, and ;; in two places those commas are followed by space, in two other ;; places they are not. (let* ((version-components (append (split-string version "\\.") '("0" "0"))) (comma-version (concat (car version-components) "," (cadr version-components) "," (cadr (cdr version-components)) "," (cadr (cdr (cdr version-components))))) (comma-space-version (concat (car version-components) ", " (cadr version-components) ", " (cadr (cdr version-components)) ", " (cadr (cdr (cdr version-components)))))) (set-version-in-file root "nt/emacs.rc" comma-version (rx (and "FILEVERSION" (1+ space) (submatch (1+ (in "0-9,")))))) (set-version-in-file root "nt/emacs.rc" comma-version (rx (and "PRODUCTVERSION" (1+ space) (submatch (1+ (in "0-9,")))))) (set-version-in-file root "nt/emacs.rc" comma-space-version (rx (and "\"FileVersion\"" (0+ space) ?, (0+ space) ?\" (submatch (1+ (in "0-9, "))) "\\0\""))) (set-version-in-file root "nt/emacs.rc" comma-space-version (rx (and "\"ProductVersion\"" (0+ space) ?, (0+ space) ?\" (submatch (1+ (in "0-9, "))) "\\0\""))) ;; Likewise for emacsclient.rc (set-version-in-file root "nt/emacsclient.rc" comma-version (rx (and "FILEVERSION" (1+ space) (submatch (1+ (in "0-9,")))))) (set-version-in-file root "nt/emacsclient.rc" comma-version (rx (and "PRODUCTVERSION" (1+ space) (submatch (1+ (in "0-9,")))))) (set-version-in-file root "nt/emacsclient.rc" comma-space-version (rx (and "\"FileVersion\"" (0+ space) ?, (0+ space) ?\" (submatch (1+ (in "0-9, "))) "\\0\""))) (set-version-in-file root "nt/emacsclient.rc" comma-space-version (rx (and "\"ProductVersion\"" (0+ space) ?, (0+ space) ?\" (submatch (1+ (in "0-9, "))) "\\0\"")))) ;; nextstep. (set-version-in-file root "nextstep/Cocoa/Emacs.base/Contents/Info.plist" version (rx (and "CFBundleGetInfoString" (1+ anything) "Emacs" (1+ space) (submatch (1+ (in "0-9.")))))) (set-version-in-file root "nextstep/Cocoa/Emacs.base/Contents/Info.plist" version (rx (and "CFBundleShortVersionString" (1+ not-newline) ?\n (0+ not-newline) "<string>" (0+ space) (submatch (1+ (in "0-9.")))))) (set-version-in-file root "nextstep/Cocoa/Emacs.base/Contents/Resources/English.lproj/InfoPlist.strings" version (rx (and "CFBundleShortVersionString" (0+ space) ?= (0+ space) ?\" (0+ space) "Version" (1+ space) (submatch (1+ (in "0-9.")))))) (set-version-in-file root "nextstep/Cocoa/Emacs.base/Contents/Resources/English.lproj/InfoPlist.strings" version (rx (and "CFBundleGetInfoString" (0+ space) ?= (0+ space) ?\" (0+ space) "Emacs version" (1+ space) (submatch (1+ (in "0-9.")))))) (set-version-in-file root "nextstep/GNUstep/Emacs.base/Resources/Info-gnustep.plist" version (rx (and "ApplicationRelease" (0+ space) ?= (0+ space) ?\" (0+ space) (submatch (1+ (in "0-9.")))))) (set-version-in-file root "nextstep/GNUstep/Emacs.base/Resources/Info-gnustep.plist" version (rx (and "FullVersionID" (0+ space) ?= (0+ space) ?\" (0+ space) "Emacs" (1+ space) (submatch (1+ (in "0-9.")))))) (set-version-in-file root "nextstep/GNUstep/Emacs.base/Resources/Emacs.desktop" version (rx (and "Version=" (submatch (1+ (in "0-9."))))))) ;; Note this makes some assumptions about form of short copyright. ;; FIXME add the \year in the refcards/*.tex files. (defun set-copyright (root copyright) "Set Emacs short copyright to COPYRIGHT in relevant files under ROOT. Root must be the root of an Emacs source tree." (interactive (list (read-directory-name "Emacs root directory: " nil nil t) (read-string "Short copyright string: " (format "Copyright (C) %s Free Software Foundation, Inc." (format-time-string "%Y"))))) (unless (file-exists-p (expand-file-name "src/emacs.c" root)) (error "%s doesn't seem to be the root of an Emacs source tree" root)) (set-version-in-file root "lisp/version.el" copyright (rx (and "emacs-copyright" (0+ space) ?\" (submatch (1+ (not (in ?\")))) ?\"))) (set-version-in-file root "lib-src/ebrowse.c" copyright (rx (and "emacs_copyright" (0+ (not (in ?\"))) ?\" (submatch (1+ (not (in ?\")))) ?\"))) (set-version-in-file root "lib-src/etags.c" copyright (rx (and "emacs_copyright" (0+ (not (in ?\"))) ?\" (submatch (1+ (not (in ?\")))) ?\"))) (set-version-in-file root "lib-src/rcs2log" copyright (rx (and "Copyright" (0+ space) ?= (0+ space) ?\' (submatch (1+ nonl))))) ;; This one is a nuisance, as it needs to be split over two lines. (string-match "\\(.*[0-9]\\{4\\} *\\)\\(.*\\)" copyright) ;; nextstep. (set-version-in-file root "nextstep/Cocoa/Emacs.base/Contents/Info.plist" copyright (rx (and "CFBundleGetInfoString" (1+ anything) "Emacs" (1+ space) (1+ (in "0-9.")) (1+ space) (submatch (1+ (not (in ?\<))))))) (set-version-in-file root "nextstep/Cocoa/Emacs.base/Contents/Resources/English.lproj/InfoPlist.strings" copyright (rx (and "NSHumanReadableCopyright" (0+ space) ?\= (0+ space) ?\" (submatch (1+ (not (in ?\"))))))) (set-version-in-file root "nextstep/GNUstep/Emacs.base/Resources/Info-gnustep.plist" copyright (rx (and "Copyright" (0+ space) ?\= (0+ space) ?\" (submatch (1+ (not (in ?\")))))))) (provide 'admin) ;; arch-tag: 4ea83636-2293-408b-884e-ad64f22a3bf5 ;;; admin.el ends here