From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Andrea Crotti Newsgroups: gmane.emacs.help Subject: Re: How to disable file extension auto-detection or auto-action? Date: Tue, 22 Mar 2011 13:17:22 +0100 Message-ID: References: NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain Content-Transfer-Encoding: 7BIT X-Trace: dough.gmane.org 1300796295 9634 80.91.229.12 (22 Mar 2011 12:18:15 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Tue, 22 Mar 2011 12:18:15 +0000 (UTC) Cc: help-gnu-emacs@gnu.org To: "Tadeus (Eus) Prastowo" <0x657573@googlemail.com> Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Tue Mar 22 13:18:11 2011 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.69) (envelope-from ) id 1Q20XK-0008Ug-OX for geh-help-gnu-emacs@m.gmane.org; Tue, 22 Mar 2011 13:18:10 +0100 Original-Received: from localhost ([127.0.0.1]:40723 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Q20XK-0001c4-6L for geh-help-gnu-emacs@m.gmane.org; Tue, 22 Mar 2011 08:18:10 -0400 Original-Received: from [140.186.70.92] (port=51144 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Q20Wc-0001aL-CC for help-gnu-emacs@gnu.org; Tue, 22 Mar 2011 08:17:27 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Q20Wa-00005b-C0 for help-gnu-emacs@gnu.org; Tue, 22 Mar 2011 08:17:25 -0400 Original-Received: from mta-2.ms.rz.rwth-aachen.de ([134.130.7.73]:41765) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Q20Wa-00005T-71 for help-gnu-emacs@gnu.org; Tue, 22 Mar 2011 08:17:24 -0400 Original-Received: from ironport-out-1.rz.rwth-aachen.de ([134.130.5.40]) by mta-2.ms.rz.RWTH-Aachen.de (Sun Java(tm) System Messaging Server 6.3-7.04 (built Sep 26 2008)) with ESMTP id <0LIG00G21KSYV170@mta-2.ms.rz.RWTH-Aachen.de> for help-gnu-emacs@gnu.org; Tue, 22 Mar 2011 13:17:22 +0100 (CET) X-IronPort-AV: E=Sophos;i="4.63,224,1299452400"; d="scan'208";a="101739398" Original-Received: from relay-2.ms.rz.rwth-aachen.de (HELO relay.rwth-aachen.de) ([134.130.7.75]) by ironport-in-1.rz.rwth-aachen.de with ESMTP; Tue, 22 Mar 2011 13:17:22 +0100 Original-Received: from plaetekopp (plaetekopp.informatik.RWTH-Aachen.DE [137.226.59.97]) by relay.rwth-aachen.de (8.14.4+Sun/8.13.8/1) with ESMTP id p2MCHMF8026969; Tue, 22 Mar 2011 13:17:22 +0100 (CET) Original-Received: from crotti by plaetekopp with local (Exim 4.72) (envelope-from ) id 1Q20WY-0005ME-5m; Tue, 22 Mar 2011 13:17:22 +0100 In-reply-to: User-Agent: Gnus/5.110016 (No Gnus v0.16) Emacs/24.0.50 (gnu/linux) X-detected-operating-system: by eggs.gnu.org: Solaris 10 (beta) X-Received-From: 134.130.7.73 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:80316 Archived-At: "Tadeus (Eus) Prastowo" <0x657573@googlemail.com> writes: > Hi! > > When working on a bug in apt-cacher[1], I needed to read the content > of *.bz2 files that actually were only text files. But, every time I > open a .bz2 file, Emacs sees the extension and does auto-decompression > resulting in an empty buffer. > > Is there a way to open a file dumbly without any sort of auto-action? > > Thank you. > > [1] http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=618996 Hi Tadeus (I think you know me :)) If the files .bz2 that you want to modify have something unique (like a path prefix) you might also add an entry to auto-mode-alist with a matching regexp. For example "bugs.*.bz2$" . fundamental-mode In this way you get automatically the desired behaviour locally. If they're all in the same directory you might even use some dir-local-variable. Hope it helps! -- GNU Emacs 24.0.50.1 (x86_64-unknown-linux-gnu, GTK+ Version 2.22.0) of 2011-03-04 on plaetekopp