Extracting contents of .tgz file

Here is how you can extract a file test.tar.gz to a directory output:

using Tar, CodecZlib

open(GzipDecompressorStream, "test.tar.gz") do io
    Tar.extract(io, "output")
end
3 Likes