* Add detection of *.tar.bz2 and *.tar.xz for `dired-do-compress' in lisp/dired-aux.el
@ 2019-06-29 12:22 朱梓豪
2019-06-29 15:00 ` Václav Haisman
0 siblings, 1 reply; 3+ messages in thread
From: 朱梓豪 @ 2019-06-29 12:22 UTC (permalink / raw)
To: emacs-devel
[-- Attachment #1.1: Type: text/plain, Size: 109 bytes --]
I found there was detection for *.tar.gz, but there's no detection for
*.tar.bz2 and *.tar.xz.
So I add it.
[-- Attachment #1.2: Type: text/html, Size: 199 bytes --]
[-- Attachment #2: 0001-Add-detection-of-.tar.bz2-and-.tar.xz-for-dired-do-c.patch --]
[-- Type: text/x-patch, Size: 918 bytes --]
From b0b748568f3939f5fda9ffa9f224ae65237e7193 Mon Sep 17 00:00:00 2001
From: Zhu Zihao <all_but_last@163.com>
Date: Sat, 29 Jun 2019 19:21:24 +0800
Subject: [PATCH] Add detection of *.tar.bz2 and *.tar.xz for
`dired-do-compress'.
Keep the consistency since we have detection for *.tar.gz.
---
lisp/dired-aux.el | 2 ++
1 file changed, 2 insertions(+)
diff --git a/lisp/dired-aux.el b/lisp/dired-aux.el
index 5e4ec4d1ec..fdd65b5714 100644
--- a/lisp/dired-aux.el
+++ b/lisp/dired-aux.el
@@ -988,7 +988,8 @@ dired-compress-file-suffixes
;; Solaris10 version of tar. Solaris10 becomes obsolete in 2021.
;; Same thing on AIX 7.1.
("\\.tar\\.gz\\'" "" "gzip -dc %i | tar -xf -")
+ ("\\.tar\\.bz2\\'" "" "bzip2 -dc %i | tar -xf -")
+ ("\\.tar\\.xz" "" "xz -dc %i | tar -xf -")
("\\.tgz\\'" "" "gzip -dc %i | tar -xf -")
("\\.gz\\'" "" "gunzip")
("\\.Z\\'" "" "uncompress")
--
2.22.0
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: Add detection of *.tar.bz2 and *.tar.xz for `dired-do-compress' in lisp/dired-aux.el
2019-06-29 12:22 朱梓豪
@ 2019-06-29 15:00 ` Václav Haisman
0 siblings, 0 replies; 3+ messages in thread
From: Václav Haisman @ 2019-06-29 15:00 UTC (permalink / raw)
To: emacs-devel
[-- Attachment #1.1: Type: text/plain, Size: 863 bytes --]
On 29. 06. 19 14:22, 朱梓豪 wrote:
> I found there was detection for *.tar.gz, but there's no detection for
> *.tar.bz2 and *.tar.xz.
>
> So I add it.
>
>
> diff --git a/lisp/dired-aux.el b/lisp/dired-aux.el
> index 5e4ec4d1ec..fdd65b5714 100644
> --- a/lisp/dired-aux.el
> +++ b/lisp/dired-aux.el
> @@ -988,7 +988,8 @@ dired-compress-file-suffixes
> ;; Solaris10 version of tar. Solaris10 becomes obsolete in 2021.
> ;; Same thing on AIX 7.1.
> ("\\.tar\\.gz\\'" "" "gzip -dc %i | tar -xf -")
> + ("\\.tar\\.bz2\\'" "" "bzip2 -dc %i | tar -xf -")
> + ("\\.tar\\.xz" "" "xz -dc %i | tar -xf -")
Unlike the other lines, this one does not have \\' at its end. Is this
intended?
> ("\\.tgz\\'" "" "gzip -dc %i | tar -xf -")
> ("\\.gz\\'" "" "gunzip")
> ("\\.Z\\'" "" "uncompress")
--
VH
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 228 bytes --]
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Add detection of *.tar.bz2 and *.tar.xz for `dired-do-compress' in lisp/dired-aux.el
@ 2019-06-30 6:50 朱梓豪
0 siblings, 0 replies; 3+ messages in thread
From: 朱梓豪 @ 2019-06-30 6:50 UTC (permalink / raw)
To: vhaisman, emacs-devel
[-- Attachment #1.1: Type: text/plain, Size: 81 bytes --]
It' just my typo. Please ignore it.
I've built a new patch instead of old ones.
[-- Attachment #1.2: Type: text/html, Size: 175 bytes --]
[-- Attachment #2: 0001-Add-detection-of-.tar.bz2-and-.tar.xz-for-dired-do-c.patch --]
[-- Type: text/x-patch, Size: 929 bytes --]
From 5bee3c8403675948f6d73d3d799ac88dc7e593bd Mon Sep 17 00:00:00 2001
From: Zhu Zihao <all_but_last@163.com>
Date: Sat, 29 Jun 2019 19:21:24 +0800
Subject: [PATCH] Add detection of *.tar.bz2 and *.tar.xz for
`dired-do-compress'.
Keep the consistency since we have detection for *.tar.gz.
Fix.
---
lisp/dired-aux.el | 2 ++
1 file changed, 2 insertions(+)
diff --git a/lisp/dired-aux.el b/lisp/dired-aux.el
index 5e4ec4d1ec..4b5bd61a40 100644
--- a/lisp/dired-aux.el
+++ b/lisp/dired-aux.el
@@ -988,6 +988,8 @@ dired-compress-file-suffixes
;; Solaris10 version of tar. Solaris10 becomes obsolete in 2021.
;; Same thing on AIX 7.1.
("\\.tar\\.gz\\'" "" "gzip -dc %i | tar -xf -")
+ ("\\.tar\\.bz2\\'" "" "bzip2 -dc %i | tar -xf -")
+ ("\\.tar\\.xz\\'" "" "unxz -c %i | tar -xf -")
("\\.tgz\\'" "" "gzip -dc %i | tar -xf -")
("\\.gz\\'" "" "gunzip")
("\\.Z\\'" "" "uncompress")
--
2.22.0
^ permalink raw reply related [flat|nested] 3+ messages in thread
end of thread, other threads:[~2019-06-30 6:50 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-06-30 6:50 Add detection of *.tar.bz2 and *.tar.xz for `dired-do-compress' in lisp/dired-aux.el 朱梓豪
-- strict thread matches above, loose matches on Subject: below --
2019-06-29 12:22 朱梓豪
2019-06-29 15:00 ` Václav Haisman
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).