From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: skuhagen@web.de Newsgroups: gmane.emacs.help Subject: Can priority of interpreter-mode-alist over auto-mode-alist be changed? Date: Thu, 27 Mar 2008 05:42:14 -0700 (PDT) Organization: http://groups.google.com Message-ID: NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1206664871 22030 80.91.229.12 (28 Mar 2008 00:41:11 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 28 Mar 2008 00:41:11 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Fri Mar 28 01:41:42 2008 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1Jf2f7-00023j-8g for geh-help-gnu-emacs@m.gmane.org; Fri, 28 Mar 2008 01:41:41 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Jf2eV-0002O7-La for geh-help-gnu-emacs@m.gmane.org; Thu, 27 Mar 2008 20:41:03 -0400 Original-Path: shelby.stanford.edu!newsfeed.stanford.edu!postnews.google.com!13g2000hsb.googlegroups.com!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 28 Original-NNTP-Posting-Host: 194.156.172.206 Original-X-Trace: posting.google.com 1206621734 25741 127.0.0.1 (27 Mar 2008 12:42:14 GMT) Original-X-Complaints-To: groups-abuse@google.com Original-NNTP-Posting-Date: Thu, 27 Mar 2008 12:42:14 +0000 (UTC) Complaints-To: groups-abuse@google.com Injection-Info: 13g2000hsb.googlegroups.com; posting-host=194.156.172.206; posting-account=6z3KhwoAAABFOdnX74O0H2dNmxuvnjw_ User-Agent: G2/1.0 X-HTTP-UserAgent: Mozilla/5.0 (compatible; Konqueror/3.5; Linux) KHTML/3.5.9 (like Gecko),gzip(gfe),gzip(gfe) X-HTTP-Via: 1.1 lxsrv88.defence-elec.de:8080 (squid/2.5.STABLE1), 1.0 lxsrv86.defence-elec.de:8080 (squid/2.5.STABLE1) Original-Xref: shelby.stanford.edu gnu.emacs.help:157367 X-Mailman-Approved-At: Thu, 27 Mar 2008 20:35:40 -0400 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:52755 Archived-At: 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