Created
December 6, 2023 09:28
-
-
Save kleutzinger/7b9a0e0c5252dda8079db8c419f8c519 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
""" | |
decompress files.tar.zst to files.tar | |
""" | |
import zstandard as zstd | |
your_filename = "files.tar.zst" | |
with open(your_filename, "rb") as f: | |
data = f.read() | |
dctx = zstd.ZstdDecompressor() | |
decompressed = dctx.decompress(data, max_output_size=104857600) | |
with open("files.tar", "wb") as f: | |
f.write(decompressed) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment