zip-vfs

1.0.2 • Public • Published

zip-vfs

Allows 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.

Installation

 $ npm install zip-vfs

Usage

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!

Readme

Keywords

none

Package Sidebar

Install

npm i zip-vfs

Weekly Downloads

0

Version

1.0.2

License

MIT

Last publish

Collaborators

  • ryotakatsuki