readzip
Advanced tools
Comparing version 1.0.1 to 2.0.0
@@ -9,7 +9,3 @@ 'use strict'; | ||
const yauzl = require('yauzl'); | ||
const {dosDateTimeToDate} = yauzl; | ||
const open = promisify(yauzl.open); | ||
const close = wraptile((a) => a.close()); | ||
const isEndSlash = (a) => a[a.length - 1] === sep; | ||
const { | ||
@@ -22,2 +18,6 @@ sep, | ||
const isEndSlash = (a) => a.at(-1) === sep; | ||
const close = wraptile((a) => a.close()); | ||
const open = promisify(yauzl.open); | ||
const {dosDateTimeToDate} = yauzl; | ||
const RW = parseInt('666', 8); | ||
@@ -55,3 +55,3 @@ | ||
]); | ||
} while(entry); | ||
} while (entry); | ||
}; | ||
@@ -62,3 +62,2 @@ | ||
const {fileName} = entry; | ||
const name = basename(fileName); | ||
@@ -74,3 +73,3 @@ this._isStop = false; | ||
this.name = name; | ||
this.name = basename(fileName); | ||
this.size = entry.uncompressedSize; | ||
@@ -109,2 +108,1 @@ this.date = dosDateTimeToDate(entry.lastModFileDate); | ||
} | ||
{ | ||
"name": "readzip", | ||
"version": "1.0.1", | ||
"version": "2.0.0", | ||
"type": "commonjs", | ||
"main": "lib/readzip.js", | ||
@@ -32,16 +33,15 @@ "description": "read zip archive in simplest possible way", | ||
"devDependencies": { | ||
"@cloudcmd/stub": "^3.1.0", | ||
"@iocmd/wait": "^1.0.0", | ||
"c8": "^7.5.0", | ||
"eslint": "^7.3.1", | ||
"eslint-plugin-node": "^11.0.0", | ||
"eslint-plugin-putout": "^7.0.0", | ||
"madrun": "^8.3.8", | ||
"memfs": "^3.2.0", | ||
"mock-fs": "^4.13.0", | ||
"@iocmd/wait": "^2.1.0", | ||
"c8": "^8.0.1", | ||
"eslint": "^8.46.0", | ||
"eslint-plugin-n": "^16.0.1", | ||
"eslint-plugin-putout": "^19.0.4", | ||
"madrun": "^9.3.1", | ||
"memfs": "^4.2.1", | ||
"mock-fs": "^5.2.0", | ||
"mock-require": "^3.0.1", | ||
"nodemon": "^2.0.2", | ||
"nodemon": "^3.0.1", | ||
"pullout": "^4.0.0", | ||
"putout": "^15.0.0", | ||
"supertape": "^4.4.0" | ||
"putout": "^31.0.5", | ||
"supertape": "^8.4.1" | ||
}, | ||
@@ -55,5 +55,5 @@ "keywords": [ | ||
"engines": { | ||
"node": ">=14" | ||
"node": ">=16" | ||
}, | ||
"license": "MIT" | ||
} |
@@ -1,2 +0,2 @@ | ||
# Readzip [![License][LicenseIMGURL]][LicenseURL] [![NPM version][NPMIMGURL]][NPMURL] [![Dependency Status][DependencyStatusIMGURL]][DependencyStatusURL] [![Build Status][BuildStatusIMGURL]][BuildStatusURL] [![Coverage Status][CoverageIMGURL]][CoverageURL] | ||
# Readzip [![License][LicenseIMGURL]][LicenseURL] [![NPM version][NPMIMGURL]][NPMURL] [![Build Status][BuildStatusIMGURL]][BuildStatusURL] [![Coverage Status][CoverageIMGURL]][CoverageURL] | ||
@@ -6,7 +6,5 @@ [NPMIMGURL]: https://img.shields.io/npm/v/readzip.svg?style=flat | ||
[BuildStatusIMGURL]: https://github.com/coderaiser/readzip/workflows/CI/badge.svg | ||
[DependencyStatusIMGURL]: https://img.shields.io/david/coderaiser/readzip.svg?style=flat | ||
[LicenseIMGURL]: https://img.shields.io/badge/license-MIT-317BF9.svg?style=flat | ||
[NPMURL]: https://npmjs.org/package/readzip "npm" | ||
[BuildStatusURL]: https://travis-ci.org/coderaiser/readzip "Build Status" | ||
[DependencyStatusURL]: https://david-dm.org/coderaiser/readzip "Dependency Status" | ||
[LicenseURL]: https://tldrlegal.com/license/mit-license "MIT License" | ||
@@ -45,2 +43,3 @@ [CoverageURL]: https://coveralls.io/github/coderaiser/readzip?branch=master | ||
import readzip from 'readzip'; | ||
const archivePath = './hello.zip'; | ||
@@ -47,0 +46,0 @@ |
Sorry, the diff of this file is not supported yet
11112
13
78
69