"Stephen J. Turnbull" <turnbull(a)sk.tsukuba.ac.jp> writes:
The patch is already in 21.2.x, but not yet in 21.1.x.
I think this is _wrong_, but since that alist is already way out of
hand, I don't see anything horrible about adding it to 21.1, too.
This is Vin Shelton's area, though, since it's 21.1.
Here's the patch to sync auto-mode-alist to 21.2.
I think it's pretty safe, but it's up to Vin whether this
patch is applied or not.
I really agree there should be a better way to handle this.
I sometimes wish I could blow up current package system and
introduce Scheme48 (or librep) like module system to XEmacs.
2000-10-25 Yoshiki Hayashi <yoshiki(a)xemacs.org>
* files.el (auto-mode-alist): Update to 21.2 version.
Index: files.el
===================================================================
RCS file: /usr/CVSroot/XEmacs/xemacs/lisp/files.el,v
retrieving revision 1.37
diff -u -r1.37 files.el
--- files.el 2000/07/31 00:33:12 1.37
+++ files.el 2000/10/25 10:08:59
@@ -1159,51 +1159,53 @@
(defvar auto-mode-alist
'(("\\.te?xt\\'" . text-mode)
- ("\\.[ch]\\'" . c-mode)
+ ("\\.[chi]\\'" . c-mode)
("\\.el\\'" . emacs-lisp-mode)
- ("\\.\\([CH]\\|cc\\|hh\\)\\'" . c++-mode)
+ ("\\.\\(?:[CH]\\|cc\\|hh\\)\\'" . c++-mode)
("\\.[ch]\\(pp\\|xx\\|\\+\\+\\)\\'" . c++-mode)
("\\.java\\'" . java-mode)
("\\.idl\\'" . idl-mode)
- ("\\.f\\(or\\)?\\'" . fortran-mode)
- ("\\.F\\(OR\\)?\\'" . fortran-mode)
+ ("\\.f\\(?:or\\)?\\'" . fortran-mode)
+ ("\\.F\\(?:OR\\)?\\'" . fortran-mode)
("\\.[fF]90\\'" . f90-mode)
;;; Less common extensions come here
;;; so more common ones above are found faster.
("\\.\\([pP][Llm]\\|al\\)\\'" . perl-mode)
("\\.py\\'" . python-mode)
- ("\\.texi\\(nfo\\)?\\'" . texinfo-mode)
+ ("\\.texi\\(?:nfo\\)?\\'" . texinfo-mode)
("\\.ad[abs]\\'" . ada-mode)
- ("\\.c?l\\(i?sp\\)?\\'" . lisp-mode)
- ("\\.p\\(as\\)?\\'" . pascal-mode)
+ ("\\.c?l\\(?:i?sp\\)?\\'" . lisp-mode)
+ ("\\.p\\(?:as\\)?\\'" . pascal-mode)
("\\.ltx\\'" . latex-mode)
("\\.[sS]\\'" . asm-mode)
- ("[Cc]hange.?[Ll]og?\\(.[0-9]+\\)?\\'" . change-log-mode)
+ ("[Cc]hange.?[Ll]og?\\(?:.[0-9]+\\)?\\'" . change-log-mode)
("\\$CHANGE_LOG\\$\\.TXT" . change-log-mode)
("\\.scm?\\(?:\\.[0-9]*\\)?\\'" . scheme-mode)
("\\.e\\'" . eiffel-mode)
("\\.mss\\'" . scribe-mode)
- ("\\.m\\([mes]\\|an\\)\\'" . nroff-mode)
+ ("\\.m\\(?:[mes]\\|an\\)\\'" . nroff-mode)
("\\.icn\\'" . icon-mode)
- ("\\.\\([ckz]?sh\\|shar\\)\\'" . sh-mode)
+ ("\\.\\(?:[ckz]?sh\\|shar\\)\\'" . sh-mode)
+ ("\\.[Pp][Rr][Oo]\\'" . idlwave-mode)
;; #### Unix-specific!
- ("/\\.\\(bash_\\|z\\)?\\(profile\\|login\\|logout\\)\\'" . sh-mode)
- ("/\\.\\([ckz]sh\\|bash\\|tcsh\\|es\\|xinit\\|startx\\)rc\\'" .
sh-mode)
- ("/\\.\\([kz]shenv\\|xsession\\)\\'" . sh-mode)
+ ("/\\.\\(?:bash_\\|z\\)?\\(profile\\|login\\|logout\\)\\'" . sh-mode)
+ ("/\\.\\(?:[ckz]sh\\|bash\\|tcsh\\|es\\|xinit\\|startx\\)rc\\'" .
sh-mode)
+ ("/\\.\\(?:[kz]shenv\\|xsession\\)\\'" . sh-mode)
+ ("\\.m?spec$" .sh-mode)
;; The following come after the ChangeLog pattern for the sake of
;; ChangeLog.1, etc. and after the .scm.[0-9] pattern too.
("\\.[12345678]\\'" . nroff-mode)
("\\.[tT]e[xX]\\'" . tex-mode)
- ("\\.\\(sty\\|cls\\|bbl\\)\\'" . latex-mode)
+ ("\\.\\(?:sty\\|cls\\|bbl\\)\\'" . latex-mode)
("\\.bib\\'" . bibtex-mode)
("\\.article\\'" . text-mode)
("\\.letter\\'" . text-mode)
- ("\\.\\(tcl\\|exp\\)\\'" . tcl-mode)
+ ("\\.\\(?:tcl\\|exp\\)\\'" . tcl-mode)
("\\.wrl\\'" . vrml-mode)
("\\.awk\\'" . awk-mode)
("\\.prolog\\'" . prolog-mode)
("\\.tar\\'" . tar-mode)
- ("\\.\\(arc\\|zip\\|lzh\\|zoo\\)\\'" . archive-mode)
+ ("\\.\\(?:arc\\|zip\\|lzh\\|zoo\\)\\'" . archive-mode)
;; Mailer puts message to be edited in /tmp/Re.... or Message
;; #### Unix-specific!
("\\`/tmp/Re" . text-mode)
@@ -1215,9 +1217,10 @@
("\\.lex\\'" . c-mode)
("\\.m\\'" . objc-mode)
("\\.oak\\'" . scheme-mode)
- ("\\.s?html?\\'" . html-mode)
- ("\\.htm?l?3\\'" . html3-mode)
- ("\\.\\(sgml?\\|dtd\\)\\'" . sgml-mode)
+ ("\\.[sj]?html?\\'" . html-mode)
+ ("\\.jsp\\'" . html-mode)
+ ("\\.xml\\'" . xml-mode)
+ ("\\.\\(?:sgml?\\|dtd\\)\\'" . sgml-mode)
("\\.c?ps\\'" . postscript-mode)
;; .emacs following a directory delimiter in either Unix or
;; Windows syntax.
@@ -1225,16 +1228,16 @@
("\\.m4\\'" . autoconf-mode)
("configure\\.in\\'" . autoconf-mode)
("\\.ml\\'" . lisp-mode)
- ("\\.ma?k\\'" . makefile-mode)
+ ("\\.ma?ke?\\'" . makefile-mode)
("[Mm]akefile\\(\\.\\|\\'\\)" . makefile-mode)
("\\.X\\(defaults\\|environment\\|resources\\|modmap\\)\\'" .
xrdb-mode)
;; #### The following three are Unix-specific (but do we care?)
("/app-defaults/" . xrdb-mode)
- ("\\.[^/]*wm\\'" . winmgr-mode)
- ("\\.[^/]*wm2?rc" . winmgr-mode)
+ ("\\.[^/]*wm2?\\(?:rc\\)?\\'" . winmgr-mode)
("\\.[Jj][Pp][Ee]?[Gg]\\'" . image-mode)
("\\.[Pp][Nn][Gg]\\'" . image-mode)
("\\.[Gg][Ii][Ff]\\'" . image-mode)
+ ("\\.[Tt][Ii][Ff][Ff]?\\'" . image-mode)
)
"Alist of filename patterns vs. corresponding major mode functions.
Each element looks like (REGEXP . FUNCTION) or (REGEXP FUNCTION NON-NIL).
--
Yoshiki Hayashi