tar_filter: recognize .tar.zst as zstd (#7093)

tar_filter: recognize .tar.zst as zstd
This commit is contained in:
nyuszika7h 2022-10-22 14:46:12 +02:00 committed by GitHub
parent 2ed7f317d3
commit 54ec166219
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 3 deletions

View File

@ -42,7 +42,7 @@ def get_tar_filter(fname, decompress):
filter = "xz -d" if decompress else "xz"
elif fname.endswith((".tar.lz4",)):
filter = "lz4 -d" if decompress else "lz4"
elif fname.endswith((".tar.zstd",)):
elif fname.endswith((".tar.zstd", ".tar.zst")):
filter = "zstd -d" if decompress else "zstd"
else:
filter = None
@ -349,7 +349,7 @@ class TarMixIn:
- .tar.gz or .tgz: gzip
- .tar.bz2 or .tbz: bzip2
- .tar.xz or .txz: xz
- .tar.zstd: zstd
- .tar.zstd or .tar.zst: zstd
- .tar.lz4: lz4
Alternatively, a ``--tar-filter`` program may be explicitly specified. It should
@ -424,7 +424,7 @@ class TarMixIn:
- .tar.gz or .tgz: gzip -d
- .tar.bz2 or .tbz: bzip2 -d
- .tar.xz or .txz: xz -d
- .tar.zstd: zstd -d
- .tar.zstd or .tar.zst: zstd -d
- .tar.lz4: lz4 -d
Alternatively, a --tar-filter program may be explicitly specified. It should