npm-pkg-lint 3.6.2 → 3.6.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +20 -14
- package/dist/index.js.map +2 -2
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -7871,7 +7871,8 @@ var argmap = /* @__PURE__ */ new Map([
|
|
|
7871
7871
|
["no-mtime", "noMtime"],
|
|
7872
7872
|
["p", "preserveOwner"],
|
|
7873
7873
|
["L", "follow"],
|
|
7874
|
-
["h", "follow"]
|
|
7874
|
+
["h", "follow"],
|
|
7875
|
+
["onentry", "onReadEntry"]
|
|
7875
7876
|
]);
|
|
7876
7877
|
var isSyncFile = (o2) => !!o2.sync && !!o2.file;
|
|
7877
7878
|
var isAsyncFile = (o2) => !o2.sync && !!o2.file;
|
|
@@ -9376,8 +9377,8 @@ var Parser = class extends EE2 {
|
|
|
9376
9377
|
if (typeof opt.onwarn === "function") {
|
|
9377
9378
|
this.on("warn", opt.onwarn);
|
|
9378
9379
|
}
|
|
9379
|
-
if (typeof opt.
|
|
9380
|
-
this.on("entry", opt.
|
|
9380
|
+
if (typeof opt.onReadEntry === "function") {
|
|
9381
|
+
this.on("entry", opt.onReadEntry);
|
|
9381
9382
|
}
|
|
9382
9383
|
}
|
|
9383
9384
|
warn(code2, message, data = {}) {
|
|
@@ -9776,10 +9777,10 @@ var stripTrailingSlashes = (str) => {
|
|
|
9776
9777
|
};
|
|
9777
9778
|
|
|
9778
9779
|
// node_modules/tar/dist/esm/list.js
|
|
9779
|
-
var
|
|
9780
|
-
const
|
|
9781
|
-
opt.
|
|
9782
|
-
|
|
9780
|
+
var onReadEntryFunction = (opt) => {
|
|
9781
|
+
const onReadEntry = opt.onReadEntry;
|
|
9782
|
+
opt.onReadEntry = onReadEntry ? (e) => {
|
|
9783
|
+
onReadEntry(e);
|
|
9783
9784
|
e.resume();
|
|
9784
9785
|
} : (e) => e.resume();
|
|
9785
9786
|
};
|
|
@@ -9859,7 +9860,7 @@ var list = makeCommand(listFileSync, listFile, (opt) => new Parser(opt), (opt) =
|
|
|
9859
9860
|
if (files == null ? void 0 : files.length)
|
|
9860
9861
|
filesFilter(opt, files);
|
|
9861
9862
|
if (!opt.noResume)
|
|
9862
|
-
|
|
9863
|
+
onReadEntryFunction(opt);
|
|
9863
9864
|
});
|
|
9864
9865
|
|
|
9865
9866
|
// node_modules/tar/dist/esm/pack.js
|
|
@@ -10546,6 +10547,7 @@ var Pack = class extends Minipass {
|
|
|
10546
10547
|
filter;
|
|
10547
10548
|
jobs;
|
|
10548
10549
|
[WRITEENTRYCLASS];
|
|
10550
|
+
onWriteEntry;
|
|
10549
10551
|
[QUEUE2];
|
|
10550
10552
|
[JOBS] = 0;
|
|
10551
10553
|
[PROCESSING] = false;
|
|
@@ -10563,6 +10565,7 @@ var Pack = class extends Minipass {
|
|
|
10563
10565
|
this.linkCache = opt.linkCache || /* @__PURE__ */ new Map();
|
|
10564
10566
|
this.statCache = opt.statCache || /* @__PURE__ */ new Map();
|
|
10565
10567
|
this.readdirCache = opt.readdirCache || /* @__PURE__ */ new Map();
|
|
10568
|
+
this.onWriteEntry = opt.onWriteEntry;
|
|
10566
10569
|
this[WRITEENTRYCLASS] = WriteEntry;
|
|
10567
10570
|
if (typeof opt.onwarn === "function") {
|
|
10568
10571
|
this.on("warn", opt.onwarn);
|
|
@@ -10602,7 +10605,7 @@ var Pack = class extends Minipass {
|
|
|
10602
10605
|
this.noMtime = !!opt.noMtime;
|
|
10603
10606
|
if (opt.mtime)
|
|
10604
10607
|
this.mtime = opt.mtime;
|
|
10605
|
-
this.filter = typeof opt.filter === "function" ? opt.filter : (
|
|
10608
|
+
this.filter = typeof opt.filter === "function" ? opt.filter : () => true;
|
|
10606
10609
|
this[QUEUE2] = new Yallist();
|
|
10607
10610
|
this[JOBS] = 0;
|
|
10608
10611
|
this.jobs = Number(opt.jobs) || 4;
|
|
@@ -10787,9 +10790,12 @@ var Pack = class extends Minipass {
|
|
|
10787
10790
|
};
|
|
10788
10791
|
}
|
|
10789
10792
|
[ENTRY](job) {
|
|
10793
|
+
var _a;
|
|
10790
10794
|
this[JOBS] += 1;
|
|
10791
10795
|
try {
|
|
10792
|
-
|
|
10796
|
+
const e = new this[WRITEENTRYCLASS](job.path, this[ENTRYOPT](job));
|
|
10797
|
+
(_a = this.onWriteEntry) == null ? void 0 : _a.call(this, e);
|
|
10798
|
+
return e.on("end", () => this[JOBDONE](job)).on("error", (er) => this.emit("error", er));
|
|
10793
10799
|
} catch (er) {
|
|
10794
10800
|
this.emit("error", er);
|
|
10795
10801
|
}
|
|
@@ -10910,7 +10916,7 @@ var addFilesSync = (p, files) => {
|
|
|
10910
10916
|
file: path5.resolve(p.cwd, file.slice(1)),
|
|
10911
10917
|
sync: true,
|
|
10912
10918
|
noResume: true,
|
|
10913
|
-
|
|
10919
|
+
onReadEntry: (entry) => p.add(entry)
|
|
10914
10920
|
});
|
|
10915
10921
|
} else {
|
|
10916
10922
|
p.add(file);
|
|
@@ -10925,7 +10931,7 @@ var addFilesAsync = async (p, files) => {
|
|
|
10925
10931
|
await list({
|
|
10926
10932
|
file: path5.resolve(String(p.cwd), file.slice(1)),
|
|
10927
10933
|
noResume: true,
|
|
10928
|
-
|
|
10934
|
+
onReadEntry: (entry) => {
|
|
10929
10935
|
p.add(entry);
|
|
10930
10936
|
}
|
|
10931
10937
|
});
|
|
@@ -12515,7 +12521,7 @@ var addFilesSync2 = (p, files) => {
|
|
|
12515
12521
|
file: path9.resolve(p.cwd, file.slice(1)),
|
|
12516
12522
|
sync: true,
|
|
12517
12523
|
noResume: true,
|
|
12518
|
-
|
|
12524
|
+
onReadEntry: (entry) => p.add(entry)
|
|
12519
12525
|
});
|
|
12520
12526
|
} else {
|
|
12521
12527
|
p.add(file);
|
|
@@ -12530,7 +12536,7 @@ var addFilesAsync2 = async (p, files) => {
|
|
|
12530
12536
|
await list({
|
|
12531
12537
|
file: path9.resolve(String(p.cwd), file.slice(1)),
|
|
12532
12538
|
noResume: true,
|
|
12533
|
-
|
|
12539
|
+
onReadEntry: (entry) => p.add(entry)
|
|
12534
12540
|
});
|
|
12535
12541
|
} else {
|
|
12536
12542
|
p.add(file);
|