help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Can priority of interpreter-mode-alist over auto-mode-alist be changed?


From: skuhagen
Subject: Can priority of interpreter-mode-alist over auto-mode-alist be changed?
Date: Thu, 27 Mar 2008 05:42:14 -0700 (PDT)
User-agent: G2/1.0

Hello all

Sorry for posting twice (here and comp.emacs), I wasn't aware of this
group...


I have a very annoying problem with auto-mode. When editing Tcl-
Files,
 which often start with

#!/bin/sh
 #\
 exec tclsh "$0" "$@"

Emacs goes into shell-script-mode instead of Tcl-mode, although the
 filename ends with .tcl.
 As far as I understand the documentation, the reason is, that
 interpreter-mode-alist is searched
 for the interpreter given in the first line, and if one is found,
the
 mode-setting from the filename
 is ignored. I don't want to change interpreter-mode-alist, but I
want
 to have the mode by filename
 have priority over mode by first line of file. Is this possible?

TIA, regards
 Stephan


reply via email to

[Prev in Thread] Current Thread [Next in Thread]