Support more .tar.whatever extensions. trunk

Sat, 04 Jul 2009 10:40:11 -0400

author
Brett Smith <brettcsmith@brettcsmith.org>
date
Sat, 04 Jul 2009 10:40:11 -0400
branch
trunk
changeset 115
d670445a0a9b
parent 114
d2a28fe2a8ff
child 116
0914040f00e7

Support more .tar.whatever extensions.

These come from Wikipedia's article on tar.

NEWS file | annotate | diff | comparison | revisions
scripts/dtrx file | annotate | diff | comparison | revisions
--- a/NEWS	Sun May 31 23:46:10 2009 -0400
+++ b/NEWS	Sat Jul 04 10:40:11 2009 -0400
@@ -12,6 +12,9 @@
    will print some incorrect listings if it misdetects the archive type of
    a given file, but it will show you an error message when that happens.
 
+ * dtrx recognizes more kinds of compressed tar archives by their
+   extension.
+
 Bug fixes
 ~~~~~~~~~
 
--- a/scripts/dtrx	Sun May 31 23:46:10 2009 -0400
+++ b/scripts/dtrx	Sat Jul 04 10:40:11 2009 -0400
@@ -881,9 +881,10 @@
         for extension in ext_info.get('extensions', ()):
             extension_map.setdefault(extension, []).append((ext_name, None))
 
-    for mapping in (('tar', 'bzip2', 'tar.bz2'),
+    for mapping in (('tar', 'bzip2', 'tar.bz2', 'tbz2', 'tb2', 'tbz'),
                     ('tar', 'gzip', 'tar.gz', 'tgz'),
                     ('tar', 'lzma', 'tar.lzma', 'tlz'),
+                    ('tar', 'compress', 'tar.Z', 'taz'),
                     ('compress', 'gzip', 'Z', 'gz'),
                     ('compress', 'bzip2', 'bz2'),
                     ('compress', 'lzma', 'lzma')):

mercurial