GNU bug report logs -
#4953
23.1.50; Dired does not deal well with xz-compressed files
Previous Next
Reported by: Sven Joachim <svenjoac <at> gmx.de>
Date: Wed, 18 Nov 2009 09:05:04 UTC
Severity: wishlist
Tags: patch
Done: Glenn Morris <rgm <at> gnu.org>
Bug is archived. No further changes may be made.
To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 4953 in the body.
You can then email your comments to 4953 AT debbugs.gnu.org in the normal way.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
bug-submit-list <at> lists.donarmstrong.com, Emacs Bugs <bug-gnu-emacs <at> gnu.org>
:
bug#4953
; Package
emacs
.
(Wed, 18 Nov 2009 09:05:05 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
Sven Joachim <svenjoac <at> gmx.de>
:
New bug report received and forwarded. Copy sent to
Emacs Bugs <bug-gnu-emacs <at> gnu.org>
.
(Wed, 18 Nov 2009 09:05:05 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> emacsbugs.donarmstrong.com (full text, mbox):
While finding xz-compressed files is handled transparently in Emacs, the
same cannot be said about their support (or rather, lack thereof) in
Dired. Two examples:
- dired-do-compress on file.xz produces file.xz.gz instead of file
- dired-do-shell-command does not offer anything for file.tar.xz (with
GNU tar 1.22, just "tar xf" unpacks it, older versions may need the
option --use-compress-program=xz).
In GNU Emacs 23.1.50.3 (i486-pc-linux-gnu, GTK+ Version 2.18.3)
of 2009-11-17 on turtle
Windowing system distributor `The X.Org Foundation', version 11.0.10605000
configured using `configure '--build=i486-pc-linux-gnu' 'build_alias=i486-pc-linux-gnu''
Important settings:
value of $LC_ALL: nil
value of $LC_COLLATE: C
value of $LC_CTYPE: nil
value of $LC_MESSAGES: nil
value of $LC_MONETARY: nil
value of $LC_NUMERIC: nil
value of $LC_TIME: nil
value of $LANG: de_DE.UTF-8
value of $XMODIFIERS: nil
locale-coding-system: utf-8-unix
default enable-multibyte-characters: t
Major mode: Dired by name
Minor modes in effect:
tooltip-mode: t
mouse-wheel-mode: t
menu-bar-mode: t
file-name-shadow-mode: t
global-font-lock-mode: t
font-lock-mode: t
blink-cursor-mode: t
global-auto-composition-mode: t
auto-composition-mode: t
auto-encryption-mode: t
auto-compression-mode: t
line-number-mode: t
transient-mark-mode: t
Recent input:
C-x k <return> C-x d <M-backspace> <M-backspace> <M-backspace>
<return> <down> <down> <down> <down> <down> <down>
<down> <down> <down> Z y Z y g M-x r e p o r t - e
m <tab> <return>
Recent messages:
For information about GNU Emacs and the GNU system, type C-h C-a.
Compress or uncompress coreutils-8.0.128-630f.tar.xz? (y or n)
Compressing /usr/local/src/coreutils-8.0.128-630f.tar.xz...done
Compress or uncompress: 1 file.
Compress or uncompress coreutils-8.0.128-630f.tar.xz.gz? (y or n)
Uncompressing /usr/local/src/coreutils-8.0.128-630f.tar.xz.gz...done
Compress or uncompress: 1 file.
Load-path shadows:
None found.
Features:
(shadow mail-extr message ecomplete rfc822 mml easymenu mml-sec
password-cache mm-decode mm-bodies mm-encode mailcap mail-parse rfc2231
rfc2047 rfc2045 qp ietf-drums mailabbrev nnheader gnus-util netrc
time-date mm-util mail-prsvr gmm-utils wid-edit mailheader canlock sha1
hex-util hashcash mail-utils emacsbug sendmail dired-aux dired
regexp-opt tooltip ediff-hook vc-hooks lisp-float-type mwheel x-win
x-dnd font-setting tool-bar dnd fontset image fringe lisp-mode register
page menu-bar rfn-eshadow timer select scroll-bar mldrag mouse jit-lock
font-lock syntax facemenu font-core frame cham georgian utf-8-lang
misc-lang vietnamese tibetan thai tai-viet lao korean japanese hebrew
greek romanian slovak czech european ethiopic indian cyrillic chinese
case-table epa-hook jka-cmpr-hook help simple abbrev loaddefs button
minibuffer faces cus-face text-properties overlay md5 base64 format env
code-pages mule custom widget hashtable-print-readable backquote
make-network-process dbusbind font-render-setting gtk x-toolkit x
multi-tty emacs)
Information forwarded
to
bug-submit-list <at> lists.donarmstrong.com, Emacs Bugs <bug-gnu-emacs <at> gnu.org>
:
bug#4953
; Package
emacs
.
(Thu, 19 Nov 2009 07:50:04 GMT)
Full text and
rfc822 format available.
Message #8 received at 4953 <at> emacsbugs.donarmstrong.com (full text, mbox):
Sven Joachim wrote:
> - dired-do-compress on file.xz produces file.xz.gz instead of file
OK, I added an unxz entry to dired-compress-file-suffixes.
> - dired-do-shell-command does not offer anything for file.tar.xz
I don't know what this means. M-x dired-do-shell-command for
foo.tar.gz doesn't seem to do anything special.
Information forwarded
to
bug-submit-list <at> lists.donarmstrong.com, Emacs Bugs <bug-gnu-emacs <at> gnu.org>
:
bug#4953
; Package
emacs
.
(Thu, 19 Nov 2009 08:00:07 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
Sven Joachim <svenjoac <at> gmx.de>
:
Extra info received and forwarded to list. Copy sent to
Emacs Bugs <bug-gnu-emacs <at> gnu.org>
.
(Thu, 19 Nov 2009 08:00:07 GMT)
Full text and
rfc822 format available.
Message #13 received at 4953 <at> emacsbugs.donarmstrong.com (full text, mbox):
On 2009-11-19 08:42 +0100, Glenn Morris wrote:
> Sven Joachim wrote:
>
>> - dired-do-compress on file.xz produces file.xz.gz instead of file
>
> OK, I added an unxz entry to dired-compress-file-suffixes.
Thanks.
>> - dired-do-shell-command does not offer anything for file.tar.xz
>
> I don't know what this means. M-x dired-do-shell-command for
> foo.tar.gz doesn't seem to do anything special.
You need to load dired-x first (Info "(dired-x) Shell Command Guessing").
Sven
Severity set to 'wishlist' from 'normal'
Request was from
Glenn Morris <rgm <at> gnu.org>
to
control <at> emacsbugs.donarmstrong.com
.
(Thu, 19 Nov 2009 22:15:04 GMT)
Full text and
rfc822 format available.
Information forwarded
to
bug-submit-list <at> lists.donarmstrong.com, Emacs Bugs <bug-gnu-emacs <at> gnu.org>
:
bug#4953
; Package
emacs
.
(Sat, 21 Nov 2009 22:05:05 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
Sven Joachim <svenjoac <at> gmx.de>
:
Extra info received and forwarded to list. Copy sent to
Emacs Bugs <bug-gnu-emacs <at> gnu.org>
.
(Sat, 21 Nov 2009 22:05:05 GMT)
Full text and
rfc822 format available.
Message #20 received at 4953 <at> emacsbugs.donarmstrong.com (full text, mbox):
tags 4953 + patch
thanks
On 2009-11-19 08:55 +0100, Sven Joachim wrote:
> On 2009-11-19 08:42 +0100, Glenn Morris wrote:
>
>> Sven Joachim wrote:
>>
>>> - dired-do-shell-command does not offer anything for file.tar.xz
>>
>> I don't know what this means. M-x dired-do-shell-command for
>> foo.tar.gz doesn't seem to do anything special.
>
> You need to load dired-x first (Info "(dired-x) Shell Command Guessing").
Here is a patch that adds support for xz-compressed files to
dired-guess-shell-alist-default, emulating the case of bzip2-compressed
files:
--8<---------------cut here---------------start------------->8---
diff --git a/lisp/dired-x.el b/lisp/dired-x.el
index 4da19f6..dce8685 100644
--- a/lisp/dired-x.el
+++ b/lisp/dired-x.el
@@ -1017,6 +1017,16 @@ dired."
;; Optional decompression.
"bunzip2")
+ ;; xz'ed archives
+ (list "\\.t\\(ar\\.\\)?xz$"
+ "unxz -c * | tar xvf -"
+ ;; Extract files into a separate subdirectory
+ '(concat "mkdir " (file-name-sans-extension file)
+ "; unxz -c * | tar -C "
+ (file-name-sans-extension file) " -xvf -")
+ ;; Optional decompression.
+ "unxz")
+
'("\\.shar\\.Z$" "zcat * | unshar")
'("\\.shar\\.g?z$" "gunzip -qc * | unshar")
@@ -1098,6 +1108,7 @@ dired."
(list "\\.g?z$" '(concat "gunzip" (if dired-guess-shell-gzip-quiet " -q")))
(list "\\.dz$" "dictunzip")
(list "\\.bz2$" "bunzip2")
+ (list "\\.xz$" "unxz")
(list "\\.Z$" "uncompress"
;; Optional conversion to gzip format.
'(concat "znew" (if dired-guess-shell-gzip-quiet " -q")
--8<---------------cut here---------------end--------------->8---
Suggested Changelog entry:
2009-11-21 Sven Joachim <svenjoac <at> gmx.de>
* dired-x.el (dired-guess-shell-alist-default): Support xz format.
Cheers,
Sven
Added tag(s) patch.
Request was from
Sven Joachim <svenjoac <at> gmx.de>
to
control <at> emacsbugs.donarmstrong.com
.
(Sat, 21 Nov 2009 22:05:07 GMT)
Full text and
rfc822 format available.
Reply sent
to
Glenn Morris <rgm <at> gnu.org>
:
You have taken responsibility.
(Mon, 23 Nov 2009 00:40:05 GMT)
Full text and
rfc822 format available.
Notification sent
to
Sven Joachim <svenjoac <at> gmx.de>
:
bug acknowledged by developer.
(Mon, 23 Nov 2009 00:40:05 GMT)
Full text and
rfc822 format available.
Message #27 received at 4953-done <at> emacsbugs.donarmstrong.com (full text, mbox):
Thanks; applied.
bug archived.
Request was from
Debbugs Internal Request <bug-gnu-emacs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Mon, 21 Dec 2009 12:24:03 GMT)
Full text and
rfc822 format available.
This bug report was last modified 15 years and 236 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.