From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Reuben Thomas Newsgroups: gmane.emacs.bugs Subject: bug#11434: 24.0.96; Determining major mode for a given file extension Date: Tue, 8 May 2012 17:44:44 +0100 Message-ID: References: <87ipg6mxv7.fsf@sc3d.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 X-Trace: dough.gmane.org 1336495569 19714 80.91.229.3 (8 May 2012 16:46:09 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Tue, 8 May 2012 16:46:09 +0000 (UTC) To: 11434@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Tue May 08 18:46:08 2012 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1SRnY5-0001nC-Gl for geb-bug-gnu-emacs@m.gmane.org; Tue, 08 May 2012 18:46:05 +0200 Original-Received: from localhost ([::1]:38885 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SRnY4-0004mf-T5 for geb-bug-gnu-emacs@m.gmane.org; Tue, 08 May 2012 12:46:04 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:42128) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SRnXx-0004gA-Oe for bug-gnu-emacs@gnu.org; Tue, 08 May 2012 12:46:02 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SRnXv-0005eH-Rw for bug-gnu-emacs@gnu.org; Tue, 08 May 2012 12:45:57 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:40374) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SRnXv-0005e8-PO for bug-gnu-emacs@gnu.org; Tue, 08 May 2012 12:45:55 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.72) (envelope-from ) id 1SRnZy-0003LN-FX for bug-gnu-emacs@gnu.org; Tue, 08 May 2012 12:48:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Reuben Thomas Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 08 May 2012 16:48:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 11434 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Original-Received: via spool by submit@debbugs.gnu.org id=B.133649563312777 (code B ref -1); Tue, 08 May 2012 16:48:02 +0000 Original-Received: (at submit) by debbugs.gnu.org; 8 May 2012 16:47:13 +0000 Original-Received: from localhost ([127.0.0.1]:41397 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1SRnZ9-0003K0-4E for submit@debbugs.gnu.org; Tue, 08 May 2012 12:47:13 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:41564) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1SRnZ5-0003Jn-V0 for submit@debbugs.gnu.org; Tue, 08 May 2012 12:47:08 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SRnWu-0005DI-JZ for submit@debbugs.gnu.org; Tue, 08 May 2012 12:44:54 -0400 Original-Received: from lists.gnu.org ([208.118.235.17]:47730) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SRnWu-0005DC-GN for submit@debbugs.gnu.org; Tue, 08 May 2012 12:44:52 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:41596) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SRnWs-00049B-Q2 for bug-gnu-emacs@gnu.org; Tue, 08 May 2012 12:44:52 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SRnWq-0005Cd-M2 for bug-gnu-emacs@gnu.org; Tue, 08 May 2012 12:44:50 -0400 Original-Received: from exprod7og113.obsmtp.com ([64.18.2.179]:53998) by eggs.gnu.org with smtp (Exim 4.71) (envelope-from ) id 1SRnWq-0005CF-Df for bug-gnu-emacs@gnu.org; Tue, 08 May 2012 12:44:48 -0400 Original-Received: from mail-wi0-f173.google.com ([209.85.212.173]) (using TLSv1) by exprod7ob113.postini.com ([64.18.6.12]) with SMTP ID DSNKT6lNfVDPQeOZHU7amUB68X3umoeTe0Dn@postini.com; Tue, 08 May 2012 09:44:48 PDT Original-Received: by wibhn9 with SMTP id hn9so801170wib.14 for ; Tue, 08 May 2012 09:44:44 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type:x-gm-message-state; bh=Z8wCVTRE8k9X2eguF6tIwC/sD7bIEo1P6xg/0Lay3Xw=; b=m6aHZs6NUREYEBz92FzygfZIzb/khH6IrkMuQNM/aq71D5QxTwLhIDZzCpkUMkFjKa FjLAuufv47w+U5eQH9J7+FbvXgui7EAp6+tp+kdVq1AY40qL/nUeC/P0dQz+eVSS3g+X Taf00fdcKbYOFq1pQ3x+kLq+5HbmatrIO6pHVCA3SN1RBrgngPl9wdZLxD84Rz2i/bFj dIINvcKUHvfotHgtl9VImQTmC4BKzOOSEplSnDPSV/EwMbK5UFvtMsOD/YJhKHTntQYO tqaXTqZHl1N+aMA40wncidvV9KAqfS+Rp9xZmE+NKJd8j++THHYtrH4Su2S9YomOr7p2 drbQ== Original-Received: by 10.180.102.101 with SMTP id fn5mr17496128wib.6.1336495484397; Tue, 08 May 2012 09:44:44 -0700 (PDT) Original-Received: by 10.180.79.135 with HTTP; Tue, 8 May 2012 09:44:44 -0700 (PDT) In-Reply-To: <87ipg6mxv7.fsf@sc3d.org> X-Gm-Message-State: ALoCoQnWSI84/uma9NocIOTkhlrhb+pDkzGPjfiNUBCq5KSWVcnXa9YySm0h/lxWD8HBpIZ1LYO2 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6, seldom 2.4 (older, 4) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:59865 Archived-At: On 8 May 2012 17:38, Reuben Thomas wrote: > For now, I propose to rename it > "*coffee-compiled*.js", but I'd appreciate suggestions as to how I could > do this better. It would be nice to be able to give set-auto-mode a > clue, in the form of a filename or an interpreter name, for cases like this. Since it's the file name, not the buffer name, that matters, my current solution is to do: (setq buffer-file-name "compiled.js") (set-auto-mode) (setq buffer-file-name nil) Does that seem reasonable? -- http://rrt.sc3d.org