npm install zip-vfsAllows mounting a zip file and manipulating it as if it was a directory using a fs-like interface.
It requires the latest version of node (uses arrow functions) and focus in the *Sync fs interface for now. Not all functions are currently implemented.
$ npm install zip-vfs
const ZipVfs = require('zip-vfs');
const vfs = new ZipVfs(file);
// List contents
vfs.readdirSync('.');
// Read a file
const text = vfs.readFileSync('some/file.txt');
// Write a file
vfs.writeFileSync('some/file.txt', 'some text');
...
Currently, these are the supported functions (check https://nodejs.org/api/fs.html for their usage):
readlinkSync
lchmodSync
removeSync
mkdirSync
readdirSync
unlinkSync
rmdirSync
readFileSync
writeFileSync
symlinkSync
renameSync
More to come!