/[emacs]/emacs/lisp/files.el
ViewVC logotype

Diff of /emacs/lisp/files.el

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.722 by pfeiffer, Thu Nov 4 20:25:08 2004 UTC revision 1.723 by pfeiffer, Wed Nov 10 00:39:54 2004 UTC
# Line 1751  in that case, this function acts as if ` Line 1751  in that case, this function acts as if `
1751       ("BROWSE\\'" . ebrowse-tree-mode)       ("BROWSE\\'" . ebrowse-tree-mode)
1752       ("\\.ebrowse\\'" . ebrowse-tree-mode)       ("\\.ebrowse\\'" . ebrowse-tree-mode)
1753       ("#\\*mail\\*" . mail-mode)       ("#\\*mail\\*" . mail-mode)
1754         ("\\.g\\'" . antlr-mode)
1755         ("\\.ses\\'" . ses-mode)
1756         ("\\.\\(soa\\|zone\\)\\'" . dns-mode)
1757         ("\\.docbook\\'" . sgml-mode)
1758         ("/config\\.\\(?:bat\\|log\\)\\'" . fundamental-mode)
1759         ;; Windows candidates may be opened case sensitively on Unix
1760         ("\\.\\(?:[iI][nN][iI]\\|[lL][sS][tT]\\|[rR][eE][gG]\\|[sS][yY][sS]\\)\\'" . conf-mode)
1761         ("\\.\\(?:desktop\\|la\\)\\'" . conf-unix-mode)
1762         ("java.+\\.conf\\'" . conf-javaprop-mode)
1763         ("\\.properties\\(?:\\.[a-zA-Z0-9._-]+\\)?\\'" . conf-javaprop-mode)
1764         ;; *.cf, *.cfg, *.conf, *.config[.local|.de_DE.UTF8|...], */config
1765         ("[/.]c\\(?:on\\)?f\\(?:i?g\\)?\\(?:\\.[a-zA-Z0-9._-]+\\)?\\'" . conf-mode)
1766         ("\\`/etc/\\(?:DIR_COLORS\\|ethers\\|.?fstab\\|.*hosts\\|lesskey\\|login\\.?de\\(?:fs\\|vperm\\)\\|mtab\\|permissions\\|protocols\\|rpc\\|services\\)\\'" . conf-space-mode)
1767         ("\\`/etc/\\(?:aliases\\|ksysguarddrc\\|opera6rc\\)\\'" . conf-mode)
1768         ;; either user's dot-files or under /etc or some such
1769         ("/\\.?\\(?:gnokiirc\\|kde.*rc\\|mime\\.types\\|wgetrc\\)\\'" . conf-mode)
1770         ;; alas not all ~/.*rc files are like this
1771         ("/\\.\\(?:enigma\\|gltron\\|hxplayer\\|net\\|neverball\\|qt/.+\\|realplayer\\|scummvm\\|sversion\\|sylpheed/.+\\|xmp\\)rc\\'" . conf-mode)
1772         ("/\\.\\(?:gdbtkinit\\|grip\\|orbital/.+txt\\|rhosts\\|tuxracer/options\\)\\'" . conf-mode)
1773         ("/\\.?X\\(?:default\\|resource\\|re\\)s\\>" . conf-xdefaults-mode)
1774         ("/X11.+app-defaults/" . conf-xdefaults-mode)
1775         ("/X11.+locale/.+/Compose\\'" . conf-colon-mode)
1776         ;; this contains everything twice, with space and with colon :-(
1777         ("/X11.+locale/compose\\.dir\\'" . conf-javaprop-mode)
1778       ;; Get rid of any trailing .n.m and try again.       ;; Get rid of any trailing .n.m and try again.
1779       ;; This is for files saved by cvs-merge that look like .#<file>.<rev>       ;; This is for files saved by cvs-merge that look like .#<file>.<rev>
1780       ;; or .#<file>.<rev>-<rev> or VC's <file>.~<rev>~.       ;; or .#<file>.<rev>-<rev> or VC's <file>.~<rev>~.
# Line 1761  in that case, this function acts as if ` Line 1785  in that case, this function acts as if `
1785       ;; for the sake of ChangeLog.1, etc.       ;; for the sake of ChangeLog.1, etc.
1786       ;; and after the .scm.[0-9] and CVS' <file>.<rev> patterns too.       ;; and after the .scm.[0-9] and CVS' <file>.<rev> patterns too.
1787       ("\\.[1-9]\\'" . nroff-mode)       ("\\.[1-9]\\'" . nroff-mode)
1788       ("\\.g\\'" . antlr-mode)       ("\\.\\(?:orig\\|in\\|[bB][aA][kK]\\)\\'" nil t)))
      ("\\.ses\\'" . ses-mode)  
      ("\\.orig\\'" nil t)               ; from patch  
      ("\\.\\(soa\\|zone\\)\\'" . dns-mode)  
      ("\\.in\\'" nil t)))  
1789    "Alist of filename patterns vs corresponding major mode functions.    "Alist of filename patterns vs corresponding major mode functions.
1790  Each element looks like (REGEXP . FUNCTION) or (REGEXP FUNCTION NON-NIL).  Each element looks like (REGEXP . FUNCTION) or (REGEXP FUNCTION NON-NIL).
1791  \(NON-NIL stands for anything that is not nil; the value does not matter.)  \(NON-NIL stands for anything that is not nil; the value does not matter.)
# Line 1847  with that interpreter in `interpreter-mo Line 1867  with that interpreter in `interpreter-mo
1867    
1868  (defvar magic-mode-alist  (defvar magic-mode-alist
1869    '(;; The < comes before the groups (but the first) to reduce backtracking.    '(;; The < comes before the groups (but the first) to reduce backtracking.
1870      ;; Is there a nicer way of getting . including \n?      ;; Is there a nicer way of getting . including \n like Perl's //s?
1871      ;; TODO: UTF-16 <?xml may be preceded by a BOM 0xff 0xfe or 0xfe 0xff.      ;; TODO: UTF-16 <?xml may be preceded by a BOM 0xff 0xfe or 0xfe 0xff.
1872      ("\\(?:<\\?xml\\s +[^>]*>\\)?\\s *<\\(?:!--\\(?:.\\|\n\\)*?-->\\s *<\\)*\\(?:!DOCTYPE\\s +[^>]*>\\s *<\\)?\\s *\\(?:!--\\(?:.\\|\n\\)*?-->\\s *<\\)*[Hh][Tt][Mm][Ll]" . html-mode)      ("\\(?:<\\?xml\\s +[^>]*>\\)?\\s *<\\(?:!--\\(?:.\\|\n\\)*?-->\\s *<\\)*\\(?:!DOCTYPE\\s +[^>]*>\\s *<\\)?\\s *\\(?:!--\\(?:.\\|\n\\)*?-->\\s *<\\)*[Hh][Tt][Mm][Ll]" . html-mode)
1873      ;; These two must come after html, because they are more general:      ;; These two must come after html, because they are more general:
1874      ("<\\?xml " . xml-mode)      ("<\\?xml " . xml-mode)
1875      ("\\s *<\\(?:!--\\(?:.\\|\n\\)*?-->\\s *<\\)*!DOCTYPE " . sgml-mode)      ("\\s *<\\(?:!--\\(?:.\\|\n\\)*?-->\\s *<\\)*!DOCTYPE " . sgml-mode)
1876      ("%![^V]" . ps-mode))      ("%![^V]" . ps-mode)
1877    "Alist of buffer beginnings vs corresponding major mode functions.      ("# xmcd " . conf-unix-mode))
1878      "Alist of buffer beginnings vs. corresponding major mode functions.
1879  Each element looks like (REGEXP . FUNCTION).  FUNCTION will be  Each element looks like (REGEXP . FUNCTION).  FUNCTION will be
1880  called, unless it is nil.")  called, unless it is nil (to allow `auto-mode-alist' to override).")
1881    
1882  (defun set-auto-mode (&optional keep-mode-if-same)  (defun set-auto-mode (&optional keep-mode-if-same)
1883    "Select major mode appropriate for current buffer.    "Select major mode appropriate for current buffer.

Legend:
Removed from v.1.722  
changed lines
  Added in v.1.723

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26