著者はjka-compr.elに当てる以下のパッチを書きました。
auto-compression-modeにbzip2を追加するものです。
免責事項:emacs-20.2でテストしただけですが、他のバージョンで動作 しないということはないと思います
emacs-20.2/lispソースディレクトリに移動します(untarした
場所がどこであれ)。jka-compr.el.diffパッチファイルを置きます(それと同じ名前の
ファイルはありません ;)。
patch < jka-compr.el.diff
と実行します。
M-x byte-compile-file jka-compr.el
とします。jka-compr.elcを安全な場所に
移動しておきます。jka-compr.elcと置き換えます。
--- jka-compr.el Sat Jul 26 17:02:39 1997
+++ jka-compr.el.new Thu Feb 5 17:44:35 1998
@@ -44,7 +44,7 @@
;; The variable, jka-compr-compression-info-list can be used to
;; customize jka-compr to work with other compression programs.
;; The default value of this variable allows jka-compr to work with
-;; Unix compress and gzip.
+;; Unix compress and gzip. David Fetter added bzip2 support :)
;;
;; If you are concerned about the stderr output of gzip and other
;; compression/decompression programs showing up in your buffers, you
@@ -121,7 +121,9 @@
;;; I have this defined so that .Z files are assumed to be in unix
-;;; compress format; and .gz files, in gzip format.
+;;; compress format; and .gz files, in gzip format, and .bz2 files,
+;;; in the snappy new bzip2 format from http://www.muraroa.demon.co.uk.
+;;; Keep up the good work, people!
(defcustom jka-compr-compression-info-list
;;[regexp
;; compr-message compr-prog compr-args
@@ -131,6 +133,10 @@
"compressing" "compress" ("-c")
"uncompressing" "uncompress" ("-c")
nil t]
+ ["\\.bz2\\'"
+ "bzip2ing" "bzip2" ("")
+ "bunzip2ing" "bzip2" ("-d")
+ nil nil]
["\\.tgz\\'"
"zipping" "gzip" ("-c" "-q")
"unzipping" "gzip" ("-c" "-q" "-d")