Closed yanzou closed 9 years ago
tar-stream parses every entry in the tar file. when parsing the tar file you visit every file/directory try doing something like this:
fs.createReadStream(FILE_PATH).pipe(zlib.createUnzip()).pipe(extract)
.on('entry', function(header, stream, callback) {
console.log(header.name)
stream.resume()
stream.on('end', function() {
callback()
})
})
this should print out all entries in the tar ball. does that make sense?
checkout tar-fs if you are looking for something that extracts the entire tar ball to your filesystem
Thanks :+1:
Hi, Sorry to raise issue here but I think you guys maintaining this module would understand this best, So I thought I might get some help from here.
I am using this module to read a .tgz file, and to read every files's content from this tar file. I am kind of stuck here
here is what I am trying to do :
.tgz
file structure:(in coffee script) Read every sub folder and file
out put: