Better font locking in emacs
I can’t believe it took me this long to realize this, but I just
figured out that in emacs auto-mode-alist takes a regular
expression as its argument to indicate the mode for some set of
files. Typically, you tell it something like “\\.html$”
should be html-mode but I can just as easily say
“/path/to/my/home/.*\\.txt$” is also “html-mode”.
I’m interested in this since blosxom’s files are html (so I’d like my
editor to treat them as such) but I left the default configuration
setting so they have the *.txt extension. A similar alist entry could
be used to make *.bat files under some path start up in cperl mode, in
case some slacker left the “# -*- mode:cperl -*-” hint off them.