home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.emacs
- Path: sparky!uunet!uunet.ca!cognos!jimp
- From: jimp@cognos.COM (Jim Patterson)
- Subject: Re: find-file-maybe-uncompress? (for Gnu under unix)
- Message-ID: <1993Jan7.205343.28668@cognos.com>
- Sender: news@cognos.com (News Administrator)
- Nntp-Posting-Host: asterix
- Organization: Cognos Incorporated, Ottawa CANADA
- X-Newsreader: Tin 1.1 PL3
- References: <lkolp9INNhg1@bathtub.cs.utexas.edu>
- Date: Thu, 7 Jan 1993 20:53:43 GMT
- Lines: 28
-
- schrag@cs.utexas.edu (Robert C. Schrag) writes:
- : Does anybody have a version of find-file (or find-file-noselect) that
- : will automatically uncompress the file, if it has the .Z suffix?
-
- Check your local Emacs lisp archive for a module called "zcat.el".
- This contains a routine called zcat-buffer that is installed as a
- minor mode (it doesn't actually replace find-file). It's installed like
- this at our site:
-
- (autoload 'zcat-buffer "site/zcat"
- "Uncompresses contents of buffer,
- respecting read-only status (not loaded)."
- t)
-
- (setq auto-mode-alist
- (append auto-mode-alist '(
- ("\\.Z$" . zcat-buffer)
- )))
-
- Once this is done during setup, zcat-buffer will automatically be
- invoked on any file with a .Z extension (quite neat). We've put it
- into our site-init.el file.
-
- --
- Jim Patterson Cognos Incorporated
- Sr Consulting Engineer P.O. BOX 9707
- UUNET:jimp@cognos.COM 3755 Riverside Drive
- PHONE:(613)738-1338 x3385 Ottawa, Ont K1G 3Z4
-