npm-pkg-lint 5.1.11 → 5.1.12
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 +54 -48
- package/dist/index.js.map +3 -3
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -7802,7 +7802,7 @@ var _ = /* @__PURE__ */ Symbol("bufferLength");
|
|
|
7802
7802
|
var bi = /* @__PURE__ */ Symbol("bufferPush");
|
|
7803
7803
|
var Ie = /* @__PURE__ */ Symbol("bufferShift");
|
|
7804
7804
|
var L = /* @__PURE__ */ Symbol("objectMode");
|
|
7805
|
-
var
|
|
7805
|
+
var S = /* @__PURE__ */ Symbol("destroyed");
|
|
7806
7806
|
var _i = /* @__PURE__ */ Symbol("error");
|
|
7807
7807
|
var Oi = /* @__PURE__ */ Symbol("emitData");
|
|
7808
7808
|
var Is = /* @__PURE__ */ Symbol("emitEnd");
|
|
@@ -7860,7 +7860,7 @@ var A = class extends Di {
|
|
|
7860
7860
|
[Ne] = false;
|
|
7861
7861
|
[qt] = null;
|
|
7862
7862
|
[_] = 0;
|
|
7863
|
-
[
|
|
7863
|
+
[S] = false;
|
|
7864
7864
|
[Jt];
|
|
7865
7865
|
[Ce] = false;
|
|
7866
7866
|
[Rt] = 0;
|
|
@@ -7909,7 +7909,7 @@ var A = class extends Di {
|
|
|
7909
7909
|
write(t, e, i) {
|
|
7910
7910
|
if (this[Ce]) return false;
|
|
7911
7911
|
if (this[Q]) throw new Error("write after end");
|
|
7912
|
-
if (this[
|
|
7912
|
+
if (this[S]) return this.emit("error", Object.assign(new Error("Cannot call write after a stream was destroyed"), { code: "ERR_STREAM_DESTROYED" })), true;
|
|
7913
7913
|
typeof e == "function" && (i = e, e = "utf8"), e || (e = "utf8");
|
|
7914
7914
|
let r = this[Z] ? jt : Yr;
|
|
7915
7915
|
if (!this[L] && !Buffer.isBuffer(t)) {
|
|
@@ -7920,7 +7920,7 @@ var A = class extends Di {
|
|
|
7920
7920
|
return this[L] ? (this[g] && this[_] !== 0 && this[Ae](true), this[g] ? this.emit("data", t) : this[bi](t), this[_] !== 0 && this.emit("readable"), i && r(i), this[g]) : t.length ? (typeof t == "string" && !(e === this[z] && !this[Mt]?.lastNeed) && (t = Buffer.from(t, e)), Buffer.isBuffer(t) && this[z] && (t = this[Mt].write(t)), this[g] && this[_] !== 0 && this[Ae](true), this[g] ? this.emit("data", t) : this[bi](t), this[_] !== 0 && this.emit("readable"), i && r(i), this[g]) : (this[_] !== 0 && this.emit("readable"), i && r(i), this[g]);
|
|
7921
7921
|
}
|
|
7922
7922
|
read(t) {
|
|
7923
|
-
if (this[
|
|
7923
|
+
if (this[S]) return null;
|
|
7924
7924
|
if (this[C] = false, this[_] === 0 || t === 0 || t && t > this[_]) return this[J](), null;
|
|
7925
7925
|
this[L] && (t = null), this[b].length > 1 && !this[L] && (this[b] = [this[z] ? this[b].join("") : Buffer.concat(this[b], this[_])]);
|
|
7926
7926
|
let e = this[Ns](t || null, this[b][0]);
|
|
@@ -7938,7 +7938,7 @@ var A = class extends Di {
|
|
|
7938
7938
|
return typeof t == "function" && (i = t, t = void 0), typeof e == "function" && (i = e, e = "utf8"), t !== void 0 && this.write(t, e), i && this.once("end", i), this[Q] = true, this.writable = false, (this[g] || !this[Qt]) && this[J](), this;
|
|
7939
7939
|
}
|
|
7940
7940
|
[Bt]() {
|
|
7941
|
-
this[
|
|
7941
|
+
this[S] || (!this[Rt] && !this[N].length && (this[C] = true), this[Qt] = false, this[g] = true, this.emit("resume"), this[b].length ? this[Ae]() : this[Q] ? this[J]() : this.emit("drain"));
|
|
7942
7942
|
}
|
|
7943
7943
|
resume() {
|
|
7944
7944
|
return this[Bt]();
|
|
@@ -7947,7 +7947,7 @@ var A = class extends Di {
|
|
|
7947
7947
|
this[g] = false, this[Qt] = true, this[C] = false;
|
|
7948
7948
|
}
|
|
7949
7949
|
get destroyed() {
|
|
7950
|
-
return this[
|
|
7950
|
+
return this[S];
|
|
7951
7951
|
}
|
|
7952
7952
|
get flowing() {
|
|
7953
7953
|
return this[g];
|
|
@@ -7971,7 +7971,7 @@ var A = class extends Di {
|
|
|
7971
7971
|
return this.emit("data", t), this[g];
|
|
7972
7972
|
}
|
|
7973
7973
|
pipe(t, e) {
|
|
7974
|
-
if (this[
|
|
7974
|
+
if (this[S]) return t;
|
|
7975
7975
|
this[C] = false;
|
|
7976
7976
|
let i = this[nt];
|
|
7977
7977
|
return e = e || {}, t === Ds.stdout || t === Ds.stderr ? e.end = false : e.end = e.end !== false, e.proxyErrors = !!e.proxyErrors, i ? e.end && t.end() : (this[N].push(e.proxyErrors ? new Li(this, t, e) : new Fe(this, t, e)), this[Z] ? jt(() => this[Bt]()) : this[Bt]()), t;
|
|
@@ -8009,15 +8009,15 @@ var A = class extends Di {
|
|
|
8009
8009
|
return this[nt];
|
|
8010
8010
|
}
|
|
8011
8011
|
[J]() {
|
|
8012
|
-
!this[De] && !this[nt] && !this[
|
|
8012
|
+
!this[De] && !this[nt] && !this[S] && this[b].length === 0 && this[Q] && (this[De] = true, this.emit("end"), this.emit("prefinish"), this.emit("finish"), this[Ne] && this.emit("close"), this[De] = false);
|
|
8013
8013
|
}
|
|
8014
8014
|
emit(t, ...e) {
|
|
8015
8015
|
let i = e[0];
|
|
8016
|
-
if (t !== "error" && t !== "close" && t !==
|
|
8016
|
+
if (t !== "error" && t !== "close" && t !== S && this[S]) return false;
|
|
8017
8017
|
if (t === "data") return !this[L] && !i ? false : this[Z] ? (jt(() => this[Oi](i)), true) : this[Oi](i);
|
|
8018
8018
|
if (t === "end") return this[Is]();
|
|
8019
8019
|
if (t === "close") {
|
|
8020
|
-
if (this[Ne] = true, !this[nt] && !this[
|
|
8020
|
+
if (this[Ne] = true, !this[nt] && !this[S]) return false;
|
|
8021
8021
|
let n = super.emit("close");
|
|
8022
8022
|
return this.removeAllListeners("close"), n;
|
|
8023
8023
|
} else if (t === "error") {
|
|
@@ -8069,7 +8069,7 @@ var A = class extends Di {
|
|
|
8069
8069
|
}
|
|
8070
8070
|
async promise() {
|
|
8071
8071
|
return new Promise((t, e) => {
|
|
8072
|
-
this.on(
|
|
8072
|
+
this.on(S, () => e(new Error("stream destroyed"))), this.on("error", (i) => e(i)), this.on("end", () => t());
|
|
8073
8073
|
});
|
|
8074
8074
|
}
|
|
8075
8075
|
[Symbol.asyncIterator]() {
|
|
@@ -8081,14 +8081,14 @@ var A = class extends Di {
|
|
|
8081
8081
|
if (r !== null) return Promise.resolve({ done: false, value: r });
|
|
8082
8082
|
if (this[Q]) return e();
|
|
8083
8083
|
let n, o, h = (d) => {
|
|
8084
|
-
this.off("data", a), this.off("end", l), this.off(
|
|
8084
|
+
this.off("data", a), this.off("end", l), this.off(S, c), e(), o(d);
|
|
8085
8085
|
}, a = (d) => {
|
|
8086
|
-
this.off("error", h), this.off("end", l), this.off(
|
|
8086
|
+
this.off("error", h), this.off("end", l), this.off(S, c), this.pause(), n({ value: d, done: !!this[Q] });
|
|
8087
8087
|
}, l = () => {
|
|
8088
|
-
this.off("error", h), this.off("data", a), this.off(
|
|
8088
|
+
this.off("error", h), this.off("data", a), this.off(S, c), e(), n({ done: true, value: void 0 });
|
|
8089
8089
|
}, c = () => h(new Error("stream destroyed"));
|
|
8090
|
-
return new Promise((d,
|
|
8091
|
-
o =
|
|
8090
|
+
return new Promise((d, y) => {
|
|
8091
|
+
o = y, n = d, this.once(S, c), this.once("error", h), this.once("end", l), this.once("data", a);
|
|
8092
8092
|
});
|
|
8093
8093
|
}, throw: e, return: e, [Symbol.asyncIterator]() {
|
|
8094
8094
|
return this;
|
|
@@ -8097,21 +8097,21 @@ var A = class extends Di {
|
|
|
8097
8097
|
}
|
|
8098
8098
|
[Symbol.iterator]() {
|
|
8099
8099
|
this[C] = false;
|
|
8100
|
-
let t = false, e = () => (this.pause(), this.off(_i, e), this.off(
|
|
8100
|
+
let t = false, e = () => (this.pause(), this.off(_i, e), this.off(S, e), this.off("end", e), t = true, { done: true, value: void 0 }), i = () => {
|
|
8101
8101
|
if (t) return e();
|
|
8102
8102
|
let r = this.read();
|
|
8103
8103
|
return r === null ? e() : { done: false, value: r };
|
|
8104
8104
|
};
|
|
8105
|
-
return this.once("end", e), this.once(_i, e), this.once(
|
|
8105
|
+
return this.once("end", e), this.once(_i, e), this.once(S, e), { next: i, throw: e, return: e, [Symbol.iterator]() {
|
|
8106
8106
|
return this;
|
|
8107
8107
|
}, [Symbol.dispose]: () => {
|
|
8108
8108
|
} };
|
|
8109
8109
|
}
|
|
8110
8110
|
destroy(t) {
|
|
8111
|
-
if (this[
|
|
8112
|
-
this[
|
|
8111
|
+
if (this[S]) return t ? this.emit("error", t) : this.emit(S), this;
|
|
8112
|
+
this[S] = true, this[C] = true, this[b].length = 0, this[_] = 0;
|
|
8113
8113
|
let e = this;
|
|
8114
|
-
return typeof e.close == "function" && !this[Ne] && e.close(), t ? this.emit("error", t) : this.emit(
|
|
8114
|
+
return typeof e.close == "function" && !this[Ne] && e.close(), t ? this.emit("error", t) : this.emit(S), this;
|
|
8115
8115
|
}
|
|
8116
8116
|
static get isStream() {
|
|
8117
8117
|
return Wr;
|
|
@@ -8862,7 +8862,7 @@ var st = /* @__PURE__ */ Symbol("queue");
|
|
|
8862
8862
|
var mt = /* @__PURE__ */ Symbol("ended");
|
|
8863
8863
|
var Yi = /* @__PURE__ */ Symbol("emittedEnd");
|
|
8864
8864
|
var At = /* @__PURE__ */ Symbol("emit");
|
|
8865
|
-
var
|
|
8865
|
+
var w = /* @__PURE__ */ Symbol("unzip");
|
|
8866
8866
|
var Xe = /* @__PURE__ */ Symbol("consumeChunk");
|
|
8867
8867
|
var qe = /* @__PURE__ */ Symbol("consumeChunkSub");
|
|
8868
8868
|
var Ki = /* @__PURE__ */ Symbol("consumeBody");
|
|
@@ -8902,7 +8902,7 @@ var rt = class extends Dn {
|
|
|
8902
8902
|
[V];
|
|
8903
8903
|
[he];
|
|
8904
8904
|
[mt] = false;
|
|
8905
|
-
[
|
|
8905
|
+
[w];
|
|
8906
8906
|
[$] = false;
|
|
8907
8907
|
[It];
|
|
8908
8908
|
[je] = false;
|
|
@@ -9012,7 +9012,13 @@ var rt = class extends Dn {
|
|
|
9012
9012
|
}
|
|
9013
9013
|
}
|
|
9014
9014
|
abort(t) {
|
|
9015
|
-
|
|
9015
|
+
if (!this[$]) {
|
|
9016
|
+
if (this[w]) {
|
|
9017
|
+
let e = this[w];
|
|
9018
|
+
e.write = () => true, e.end = () => e, e.emit = () => false, e.destroy?.();
|
|
9019
|
+
}
|
|
9020
|
+
this[$] = true, this.emit("abort", t), this.warn("TAR_ABORT", t, { recoverable: false });
|
|
9021
|
+
}
|
|
9016
9022
|
}
|
|
9017
9023
|
[Xs](t) {
|
|
9018
9024
|
this[$i] += t.length;
|
|
@@ -9021,11 +9027,11 @@ var rt = class extends Dn {
|
|
|
9021
9027
|
}
|
|
9022
9028
|
write(t, e, i) {
|
|
9023
9029
|
if (typeof e == "function" && (i = e, e = void 0), typeof t == "string" && (t = Buffer.from(t, typeof e == "string" ? e : "utf8")), this[$]) return i?.(), false;
|
|
9024
|
-
if ((this[
|
|
9030
|
+
if ((this[w] === void 0 || this.brotli === void 0 && this[w] === false) && t) {
|
|
9025
9031
|
if (this[p] && (t = Buffer.concat([this[p], t]), this[p] = void 0), t.length < An) return this[p] = t, i?.(), true;
|
|
9026
|
-
for (let a = 0; this[
|
|
9032
|
+
for (let a = 0; this[w] === void 0 && a < Xi.length; a++) t[a] !== Xi[a] && (this[w] = false);
|
|
9027
9033
|
let o = false;
|
|
9028
|
-
if (this[
|
|
9034
|
+
if (this[w] === false && this.zstd !== false) {
|
|
9029
9035
|
o = true;
|
|
9030
9036
|
for (let a = 0; a < qi.length; a++) if (t[a] !== qi[a]) {
|
|
9031
9037
|
o = false;
|
|
@@ -9033,27 +9039,27 @@ var rt = class extends Dn {
|
|
|
9033
9039
|
}
|
|
9034
9040
|
}
|
|
9035
9041
|
let h = this.brotli === void 0 && !o;
|
|
9036
|
-
if (this[
|
|
9042
|
+
if (this[w] === false && h) if (t.length < 512) if (this[mt]) this.brotli = true;
|
|
9037
9043
|
else return this[p] = t, i?.(), true;
|
|
9038
9044
|
else try {
|
|
9039
9045
|
new F(t.subarray(0, 512)), this.brotli = false;
|
|
9040
9046
|
} catch {
|
|
9041
9047
|
this.brotli = true;
|
|
9042
9048
|
}
|
|
9043
|
-
if (this[
|
|
9049
|
+
if (this[w] === void 0 || this[w] === false && (this.brotli || o)) {
|
|
9044
9050
|
let a = this[mt];
|
|
9045
|
-
this[mt] = false, this[
|
|
9051
|
+
this[mt] = false, this[w] = this[w] === void 0 ? new Ue({}) : o ? new Ke({}) : new Ge({}), this[w].on("data", (c) => {
|
|
9046
9052
|
this[Xs](c) && this[Xe](c);
|
|
9047
|
-
}), this[
|
|
9053
|
+
}), this[w].on("error", (c) => {
|
|
9048
9054
|
this[$] || this.abort(c);
|
|
9049
|
-
}), this[
|
|
9055
|
+
}), this[w].on("end", () => {
|
|
9050
9056
|
this[mt] = true, this[Xe]();
|
|
9051
9057
|
}), this[Yt] = true, this[le] += t.length;
|
|
9052
|
-
let l = !!this[
|
|
9058
|
+
let l = !!this[w][a ? "end" : "write"](t);
|
|
9053
9059
|
return this[Yt] = false, i?.(), l;
|
|
9054
9060
|
}
|
|
9055
9061
|
}
|
|
9056
|
-
this[Yt] = true, this[
|
|
9062
|
+
this[Yt] = true, this[w] ? (this[le] += t.length, this[w].write(t)) : this[Xe](t), this[Yt] = false;
|
|
9057
9063
|
let n = this[st].length > 0 ? false : this[it] ? this[it].flowing : true;
|
|
9058
9064
|
return !n && this[st].length === 0 && this[it]?.once("drain", () => this.emit("drain")), i?.(), n;
|
|
9059
9065
|
}
|
|
@@ -9108,7 +9114,7 @@ var rt = class extends Dn {
|
|
|
9108
9114
|
e < i && (this[p] = this[p] ? Buffer.concat([t.subarray(e), this[p]]) : t.subarray(e));
|
|
9109
9115
|
}
|
|
9110
9116
|
end(t, e, i) {
|
|
9111
|
-
return typeof t == "function" && (i = t, e = void 0, t = void 0), typeof e == "function" && (i = e, e = void 0), typeof t == "string" && (t = Buffer.from(t, e)), i && this.once("finish", i), this[$] || (this[
|
|
9117
|
+
return typeof t == "function" && (i = t, e = void 0, t = void 0), typeof e == "function" && (i = e, e = void 0), typeof t == "string" && (t = Buffer.from(t, e)), i && this.once("finish", i), this[$] || (this[w] ? (t && (this[le] += t.length, this[w].write(t)), this[w].end()) : (this[mt] = true, (this.brotli === void 0 || this.zstd === void 0) && (t = t || Buffer.alloc(0)), t && this.write(t), this[Qe]())), this;
|
|
9112
9118
|
}
|
|
9113
9119
|
};
|
|
9114
9120
|
var ut = (s3) => {
|
|
@@ -9997,13 +10003,13 @@ var no = (s3, t) => {
|
|
|
9997
10003
|
};
|
|
9998
10004
|
var gr = (s3, t, e) => {
|
|
9999
10005
|
s3 = f(s3);
|
|
10000
|
-
let i = t.umask ?? 18, r = t.mode | 448, n = (r & i) !== 0, o = t.uid, h = t.gid, a = typeof o == "number" && typeof h == "number" && (o !== t.processUid || h !== t.processGid), l = t.preserve, c = t.unlink, d = f(t.cwd),
|
|
10001
|
-
E ? e(E) : x && a ? Es(x, o, h, (Le) =>
|
|
10006
|
+
let i = t.umask ?? 18, r = t.mode | 448, n = (r & i) !== 0, o = t.uid, h = t.gid, a = typeof o == "number" && typeof h == "number" && (o !== t.processUid || h !== t.processGid), l = t.preserve, c = t.unlink, d = f(t.cwd), y = (E, x) => {
|
|
10007
|
+
E ? e(E) : x && a ? Es(x, o, h, (Le) => y(Le)) : n ? k.chmod(s3, r, e) : e();
|
|
10002
10008
|
};
|
|
10003
|
-
if (s3 === d) return no(s3,
|
|
10004
|
-
if (l) return ro.mkdir(s3, { mode: r, recursive: true }).then((E) =>
|
|
10009
|
+
if (s3 === d) return no(s3, y);
|
|
10010
|
+
if (l) return ro.mkdir(s3, { mode: r, recursive: true }).then((E) => y(null, E ?? void 0), y);
|
|
10005
10011
|
let D = f(Si.relative(d, s3)).split("/");
|
|
10006
|
-
Ss(d, D, r, c, d, void 0,
|
|
10012
|
+
Ss(d, D, r, c, d, void 0, y);
|
|
10007
10013
|
};
|
|
10008
10014
|
var Ss = (s3, t, e, i, r, n, o) => {
|
|
10009
10015
|
if (t.length === 0) return o(null, n);
|
|
@@ -10313,12 +10319,12 @@ var Xt = class extends rt {
|
|
|
10313
10319
|
if (typeof l == "number" && t.mtime && !this.noMtime) {
|
|
10314
10320
|
n++;
|
|
10315
10321
|
let c = t.atime || /* @__PURE__ */ new Date(), d = t.mtime;
|
|
10316
|
-
m.futimes(l, c, d, (
|
|
10322
|
+
m.futimes(l, c, d, (y) => y ? m.utimes(a, c, d, (T) => o(T && y)) : o());
|
|
10317
10323
|
}
|
|
10318
10324
|
if (typeof l == "number" && this[ge](t)) {
|
|
10319
10325
|
n++;
|
|
10320
10326
|
let c = this[be](t), d = this[_e](t);
|
|
10321
|
-
typeof c == "number" && typeof d == "number" && m.fchown(l, c, d, (
|
|
10327
|
+
typeof c == "number" && typeof d == "number" && m.fchown(l, c, d, (y) => y ? m.chown(a, c, d, (T) => o(T && y)) : o());
|
|
10322
10328
|
}
|
|
10323
10329
|
o();
|
|
10324
10330
|
});
|
|
@@ -10645,27 +10651,27 @@ var go = (s3, t) => {
|
|
|
10645
10651
|
T ? v.close(n, (E) => h(T)) : h(null, D);
|
|
10646
10652
|
}, l = 0;
|
|
10647
10653
|
if (o === 0) return a(null, 0);
|
|
10648
|
-
let c = 0, d = Buffer.alloc(512),
|
|
10654
|
+
let c = 0, d = Buffer.alloc(512), y = (T, D) => {
|
|
10649
10655
|
if (T || D === void 0) return a(T);
|
|
10650
|
-
if (c += D, c < 512 && D) return v.read(n, d, c, d.length - c, l + c,
|
|
10656
|
+
if (c += D, c < 512 && D) return v.read(n, d, c, d.length - c, l + c, y);
|
|
10651
10657
|
if (l === 0 && d[0] === 31 && d[1] === 139) return a(new Error("cannot append to compressed archives"));
|
|
10652
10658
|
if (c < 512) return a(null, l);
|
|
10653
10659
|
let E = new F(d);
|
|
10654
10660
|
if (!E.cksumValid) return a(null, l);
|
|
10655
10661
|
let x = 512 * Math.ceil((E.size ?? 0) / 512);
|
|
10656
10662
|
if (l + x + 512 > o || (l += x + 512, l >= o)) return a(null, l);
|
|
10657
|
-
s3.mtimeCache && E.mtime && s3.mtimeCache.set(String(E.path), E.mtime), c = 0, v.read(n, d, 0, 512, l,
|
|
10663
|
+
s3.mtimeCache && E.mtime && s3.mtimeCache.set(String(E.path), E.mtime), c = 0, v.read(n, d, 0, 512, l, y);
|
|
10658
10664
|
};
|
|
10659
|
-
v.read(n, d, 0, 512, l,
|
|
10665
|
+
v.read(n, d, 0, 512, l, y);
|
|
10660
10666
|
};
|
|
10661
10667
|
return new Promise((n, o) => {
|
|
10662
10668
|
e.on("error", o);
|
|
10663
10669
|
let h = "r+", a = (l, c) => {
|
|
10664
10670
|
if (l && l.code === "ENOENT" && h === "r+") return h = "w+", v.open(s3.file, h, a);
|
|
10665
10671
|
if (l || !c) return o(l);
|
|
10666
|
-
v.fstat(c, (d,
|
|
10672
|
+
v.fstat(c, (d, y) => {
|
|
10667
10673
|
if (d) return v.close(c, () => o(d));
|
|
10668
|
-
i(c,
|
|
10674
|
+
i(c, y.size, (T, D) => {
|
|
10669
10675
|
if (T) return o(T);
|
|
10670
10676
|
let E = new et(s3.file, { fd: c, start: D });
|
|
10671
10677
|
e.pipe(E), E.on("error", o), E.on("close", n), _o(e, t);
|