Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions HISTORY.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@ History
* XXX
-->

## 0.4.2

* Update dependencies to fix security vulnerabilities.

## 0.4.1

* Add `--filter` option.
Expand Down
5 changes: 3 additions & 2 deletions lib/package.js
Original file line number Diff line number Diff line change
Expand Up @@ -124,10 +124,11 @@ var extract = function (obj, callback) {

var extractedDir = path.resolve(obj.tmpDir, "extracted");

fs.mkdirSync(extractedDir);
fs.createReadStream(obj.npmPack)
.pipe(zlib.createUnzip())
.pipe(new tar.Extract({
path: extractedDir,
.pipe(tar.extract({
cwd: extractedDir,
strip: 1 // Get rid of `<package-name>/` level of directory
}))
.on("error", callback)
Expand Down
11 changes: 6 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
"version": "0.4.1",
"description": "Preview npm publish changes.",
"main": "lib/index.js",
"packageManager": "yarn@1.22.22",
"scripts": {
"lint": "eslint bin lib",
"test": "npm run lint"
Expand All @@ -18,15 +19,15 @@
"publish-diff": "bin/publish-diff.js"
},
"dependencies": {
"async": "^2.1.1",
"async": "^2.6.4",
"chalk": "^1.1.3",
"commander": "^2.9.0",
"diff": "^3.0.1",
"diff": "^3.5.0",
"file-type": "^3.8.0",
"isbinaryfile": "^3.0.1",
"minimatch": "^3.0.4",
"recursive-readdir": "^2.1.0",
"tar": "^2.2.1",
"minimatch": "^3.1.2",
"recursive-readdir": "^2.2.3",
"tar": "^7.4.3",
"temp": "^0.8.3"
},
"devDependencies": {
Expand Down
Loading