Zig
Zig
UnGzip .tgz to get a .tar
See more Tar Archive Examples
A .tgz is simply a TAR archive compressed using GZip. It is also commonly referred to as a .tar.gz. Chilkat GZip can be used to ungzip to get an uncompressed .tar.Chilkat Zig Downloads
const std = @import("std");
const chilkat = @import("chilkat");
pub fn main(init: std.process.Init) !void {
const alloc = init.arena.allocator();
var success: bool = false;
const gzip = try chilkat.Gzip.init();
defer gzip.deinit();
success = if (gzip.uncompressFile("qa_data/tar/test.tgz", "qa_output/test.tar")) true else |_| false;
if (!success) {
std.debug.print("{s}\n", .{try gzip.getLastErrorText(alloc)});
} else {
std.debug.print("success.\n", .{});
}
}