From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Mike H Newsgroups: gmane.emacs.help Subject: Re: How to associate more than two file-types as C code, code included Date: Tue, 4 Dec 2007 09:27:52 -0800 (PST) Organization: http://groups.google.com Message-ID: References: NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=EUC-KR Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1196790195 11510 80.91.229.12 (4 Dec 2007 17:43:15 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 4 Dec 2007 17:43:15 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Tue Dec 04 18:43:24 2007 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 1Izbnj-0000jG-Sp for geh-help-gnu-emacs@m.gmane.org; Tue, 04 Dec 2007 18:43:20 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1IzbnT-0006xI-CK for geh-help-gnu-emacs@m.gmane.org; Tue, 04 Dec 2007 12:43:03 -0500 Original-Path: shelby.stanford.edu!newsfeed.stanford.edu!postnews.google.com!l16g2000hsf.googlegroups.com!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 29 Original-NNTP-Posting-Host: 128.61.82.20 Original-X-Trace: posting.google.com 1196789273 3429 127.0.0.1 (4 Dec 2007 17:27:53 GMT) Original-X-Complaints-To: groups-abuse@google.com Original-NNTP-Posting-Date: Tue, 4 Dec 2007 17:27:53 +0000 (UTC) Complaints-To: groups-abuse@google.com Injection-Info: l16g2000hsf.googlegroups.com; posting-host=128.61.82.20; posting-account=X0wLfwoAAACMUj0bN175vFl3ydbOJBp5 User-Agent: G2/1.0 X-HTTP-UserAgent: Mozilla/4.0 (compatible; MSIE 7.0; Windows NT 5.1; .NET CLR 2.0.50727; InfoPath.1),gzip(gfe),gzip(gfe) Content-Disposition: inline Original-Xref: shelby.stanford.edu gnu.emacs.help:154394 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:49821 Archived-At: On 12=BF=F94=C0=CF, =BF=C0=C0=FC7=BD=C359=BA=D0, Peter Dyballa wrote: > Am 03.12.2007 um 23:50 schrieb Mike H: > > > I want the files .cu and .txx to be recognized as C files.. > > One block of the following codes works separately, but when I put them > > together.. it doesn't work. > > > How should I do it ? > > > when ((string-match "\\.cu$" fn) || (string-match "\\.txx$" fn)) > > I use or instead of the shell construct ||: > > (if (or (string-match "23.0.50" mEV) (string-match "22." mEV)) ...= > > There is also the variable auto-mode-alist that you can modify like in: > > (add-to-list 'auto-mode-alist '("\\.drv\\'" . latex-mode)) > > -- > Greetings > > Pete > > "A mathematician is a machine that turns coffee into theorems." Thanks !