npm-pkg-lint 4.5.0 → 4.5.2

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 CHANGED
@@ -7691,85 +7691,85 @@ function isBlacklisted(filename2) {
7691
7691
  import fs3 from "node:fs";
7692
7692
 
7693
7693
  // node_modules/tar/dist/esm/index.min.js
7694
- import Hr from "events";
7694
+ import Ur from "events";
7695
7695
  import I from "fs";
7696
- import { EventEmitter as Oi } from "node:events";
7697
- import Ds from "node:stream";
7698
- import { StringDecoder as Ir } from "node:string_decoder";
7699
- import or from "node:path";
7696
+ import { EventEmitter as Ti } from "node:events";
7697
+ import Ns from "node:stream";
7698
+ import { StringDecoder as Dr } from "node:string_decoder";
7699
+ import nr from "node:path";
7700
7700
  import Vt from "node:fs";
7701
- import { dirname as bn, parse as gn } from "path";
7702
- import { EventEmitter as wn } from "events";
7703
- import vi from "assert";
7704
- import { Buffer as _t } from "buffer";
7705
- import * as vs from "zlib";
7706
- import Yr from "zlib";
7701
+ import { dirname as Rn, parse as bn } from "path";
7702
+ import { EventEmitter as En } from "events";
7703
+ import Mi from "assert";
7704
+ import { Buffer as gt } from "buffer";
7705
+ import * as ks from "zlib";
7706
+ import Zr from "zlib";
7707
7707
  import { posix as Zt } from "node:path";
7708
- import { basename as dn } from "node:path";
7709
- import ci from "fs";
7708
+ import { basename as fn } from "node:path";
7709
+ import fi from "fs";
7710
7710
  import $2 from "fs";
7711
- import Xs from "path";
7712
- import { win32 as xn } from "node:path";
7713
- import rr from "path";
7714
- import Lr from "node:fs";
7715
- import io from "node:assert";
7716
- import { randomBytes as xr } from "node:crypto";
7711
+ import $s from "path";
7712
+ import { win32 as Tn } from "node:path";
7713
+ import sr from "path";
7714
+ import xr from "node:fs";
7715
+ import eo from "node:assert";
7716
+ import { randomBytes as Tr } from "node:crypto";
7717
7717
  import u from "node:fs";
7718
7718
  import R from "node:path";
7719
- import lr from "fs";
7720
- import ui from "node:fs";
7719
+ import ar from "fs";
7720
+ import mi from "node:fs";
7721
7721
  import Ee from "node:path";
7722
7722
  import k from "node:fs";
7723
- import qn from "node:fs/promises";
7724
- import mi from "node:path";
7725
- import { join as Er } from "node:path";
7723
+ import Xn from "node:fs/promises";
7724
+ import pi from "node:path";
7725
+ import { join as pr } from "node:path";
7726
7726
  import v from "node:fs";
7727
- import Nr from "node:path";
7728
- var Dr = Object.defineProperty;
7727
+ import Lr from "node:path";
7728
+ var Nr = Object.defineProperty;
7729
7729
  var Ar = (s3, t) => {
7730
- for (var e in t) Dr(s3, e, { get: t[e], enumerable: true });
7730
+ for (var e in t) Nr(s3, e, { get: t[e], enumerable: true });
7731
7731
  };
7732
- var Ts = typeof process == "object" && process ? process : { stdout: null, stderr: null };
7733
- var Cr = (s3) => !!s3 && typeof s3 == "object" && (s3 instanceof A || s3 instanceof Ds || Fr(s3) || kr(s3));
7734
- var Fr = (s3) => !!s3 && typeof s3 == "object" && s3 instanceof Oi && typeof s3.pipe == "function" && s3.pipe !== Ds.Writable.prototype.pipe;
7735
- var kr = (s3) => !!s3 && typeof s3 == "object" && s3 instanceof Oi && typeof s3.write == "function" && typeof s3.end == "function";
7732
+ var Os = typeof process == "object" && process ? process : { stdout: null, stderr: null };
7733
+ var Ir = (s3) => !!s3 && typeof s3 == "object" && (s3 instanceof D || s3 instanceof Ns || Cr(s3) || Fr(s3));
7734
+ var Cr = (s3) => !!s3 && typeof s3 == "object" && s3 instanceof Ti && typeof s3.pipe == "function" && s3.pipe !== Ns.Writable.prototype.pipe;
7735
+ var Fr = (s3) => !!s3 && typeof s3 == "object" && s3 instanceof Ti && typeof s3.write == "function" && typeof s3.end == "function";
7736
7736
  var q = /* @__PURE__ */ Symbol("EOF");
7737
7737
  var j = /* @__PURE__ */ Symbol("maybeEmitEnd");
7738
7738
  var rt = /* @__PURE__ */ Symbol("emittedEnd");
7739
- var xe = /* @__PURE__ */ Symbol("emittingEnd");
7739
+ var Le = /* @__PURE__ */ Symbol("emittingEnd");
7740
7740
  var jt = /* @__PURE__ */ Symbol("emittedError");
7741
- var Le = /* @__PURE__ */ Symbol("closed");
7742
- var xs = /* @__PURE__ */ Symbol("read");
7743
- var Ne = /* @__PURE__ */ Symbol("flush");
7744
- var Ls = /* @__PURE__ */ Symbol("flushChunk");
7741
+ var Ne = /* @__PURE__ */ Symbol("closed");
7742
+ var Ts = /* @__PURE__ */ Symbol("read");
7743
+ var Ae = /* @__PURE__ */ Symbol("flush");
7744
+ var xs = /* @__PURE__ */ Symbol("flushChunk");
7745
7745
  var z = /* @__PURE__ */ Symbol("encoding");
7746
7746
  var Mt = /* @__PURE__ */ Symbol("decoder");
7747
7747
  var b = /* @__PURE__ */ Symbol("flowing");
7748
7748
  var Qt = /* @__PURE__ */ Symbol("paused");
7749
7749
  var Bt = /* @__PURE__ */ Symbol("resume");
7750
- var g = /* @__PURE__ */ Symbol("buffer");
7751
- var D = /* @__PURE__ */ Symbol("pipes");
7752
- var _ = /* @__PURE__ */ Symbol("bufferLength");
7753
- var Si = /* @__PURE__ */ Symbol("bufferPush");
7750
+ var _ = /* @__PURE__ */ Symbol("buffer");
7751
+ var A = /* @__PURE__ */ Symbol("pipes");
7752
+ var g = /* @__PURE__ */ Symbol("bufferLength");
7753
+ var yi = /* @__PURE__ */ Symbol("bufferPush");
7754
7754
  var De = /* @__PURE__ */ Symbol("bufferShift");
7755
7755
  var L = /* @__PURE__ */ Symbol("objectMode");
7756
7756
  var w = /* @__PURE__ */ Symbol("destroyed");
7757
- var yi = /* @__PURE__ */ Symbol("error");
7758
- var Ri = /* @__PURE__ */ Symbol("emitData");
7759
- var Ns = /* @__PURE__ */ Symbol("emitEnd");
7760
- var bi = /* @__PURE__ */ Symbol("emitEnd2");
7757
+ var Ri = /* @__PURE__ */ Symbol("error");
7758
+ var bi = /* @__PURE__ */ Symbol("emitData");
7759
+ var Ls = /* @__PURE__ */ Symbol("emitEnd");
7760
+ var _i = /* @__PURE__ */ Symbol("emitEnd2");
7761
7761
  var Z = /* @__PURE__ */ Symbol("async");
7762
7762
  var gi = /* @__PURE__ */ Symbol("abort");
7763
- var Ae = /* @__PURE__ */ Symbol("aborted");
7763
+ var Ie = /* @__PURE__ */ Symbol("aborted");
7764
7764
  var Jt = /* @__PURE__ */ Symbol("signal");
7765
7765
  var yt = /* @__PURE__ */ Symbol("dataListeners");
7766
7766
  var C = /* @__PURE__ */ Symbol("discarded");
7767
7767
  var te = (s3) => Promise.resolve().then(s3);
7768
- var vr = (s3) => s3();
7769
- var Mr = (s3) => s3 === "end" || s3 === "finish" || s3 === "prefinish";
7770
- var Br = (s3) => s3 instanceof ArrayBuffer || !!s3 && typeof s3 == "object" && s3.constructor && s3.constructor.name === "ArrayBuffer" && s3.byteLength >= 0;
7771
- var Pr = (s3) => !Buffer.isBuffer(s3) && ArrayBuffer.isView(s3);
7772
- var Ie = class {
7768
+ var kr = (s3) => s3();
7769
+ var vr = (s3) => s3 === "end" || s3 === "finish" || s3 === "prefinish";
7770
+ var Mr = (s3) => s3 instanceof ArrayBuffer || !!s3 && typeof s3 == "object" && s3.constructor && s3.constructor.name === "ArrayBuffer" && s3.byteLength >= 0;
7771
+ var Br = (s3) => !Buffer.isBuffer(s3) && ArrayBuffer.isView(s3);
7772
+ var Ce = class {
7773
7773
  src;
7774
7774
  dest;
7775
7775
  opts;
@@ -7786,7 +7786,7 @@ var Ie = class {
7786
7786
  this.unpipe(), this.opts.end && this.dest.end();
7787
7787
  }
7788
7788
  };
7789
- var _i = class extends Ie {
7789
+ var Oi = class extends Ce {
7790
7790
  unpipe() {
7791
7791
  this.src.removeListener("error", this.proxyErrors), super.unpipe();
7792
7792
  }
@@ -7794,26 +7794,26 @@ var _i = class extends Ie {
7794
7794
  super(t, e, i), this.proxyErrors = (r) => this.dest.emit("error", r), t.on("error", this.proxyErrors);
7795
7795
  }
7796
7796
  };
7797
- var zr = (s3) => !!s3.objectMode;
7798
- var Ur = (s3) => !s3.objectMode && !!s3.encoding && s3.encoding !== "buffer";
7799
- var A = class extends Oi {
7797
+ var Pr = (s3) => !!s3.objectMode;
7798
+ var zr = (s3) => !s3.objectMode && !!s3.encoding && s3.encoding !== "buffer";
7799
+ var D = class extends Ti {
7800
7800
  [b] = false;
7801
7801
  [Qt] = false;
7802
- [D] = [];
7803
- [g] = [];
7802
+ [A] = [];
7803
+ [_] = [];
7804
7804
  [L];
7805
7805
  [z];
7806
7806
  [Z];
7807
7807
  [Mt];
7808
7808
  [q] = false;
7809
7809
  [rt] = false;
7810
- [xe] = false;
7811
7810
  [Le] = false;
7811
+ [Ne] = false;
7812
7812
  [jt] = null;
7813
- [_] = 0;
7813
+ [g] = 0;
7814
7814
  [w] = false;
7815
7815
  [Jt];
7816
- [Ae] = false;
7816
+ [Ie] = false;
7817
7817
  [yt] = 0;
7818
7818
  [C] = false;
7819
7819
  writable = true;
@@ -7821,12 +7821,12 @@ var A = class extends Oi {
7821
7821
  constructor(...t) {
7822
7822
  let e = t[0] || {};
7823
7823
  if (super(), e.objectMode && typeof e.encoding == "string") throw new TypeError("Encoding and objectMode may not be used together");
7824
- zr(e) ? (this[L] = true, this[z] = null) : Ur(e) ? (this[z] = e.encoding, this[L] = false) : (this[L] = false, this[z] = null), this[Z] = !!e.async, this[Mt] = this[z] ? new Ir(this[z]) : null, e && e.debugExposeBuffer === true && Object.defineProperty(this, "buffer", { get: () => this[g] }), e && e.debugExposePipes === true && Object.defineProperty(this, "pipes", { get: () => this[D] });
7824
+ Pr(e) ? (this[L] = true, this[z] = null) : zr(e) ? (this[z] = e.encoding, this[L] = false) : (this[L] = false, this[z] = null), this[Z] = !!e.async, this[Mt] = this[z] ? new Dr(this[z]) : null, e && e.debugExposeBuffer === true && Object.defineProperty(this, "buffer", { get: () => this[_] }), e && e.debugExposePipes === true && Object.defineProperty(this, "pipes", { get: () => this[A] });
7825
7825
  let { signal: i } = e;
7826
7826
  i && (this[Jt] = i, i.aborted ? this[gi]() : i.addEventListener("abort", () => this[gi]()));
7827
7827
  }
7828
7828
  get bufferLength() {
7829
- return this[_];
7829
+ return this[g];
7830
7830
  }
7831
7831
  get encoding() {
7832
7832
  return this[z];
@@ -7850,46 +7850,46 @@ var A = class extends Oi {
7850
7850
  this[Z] = this[Z] || !!t;
7851
7851
  }
7852
7852
  [gi]() {
7853
- this[Ae] = true, this.emit("abort", this[Jt]?.reason), this.destroy(this[Jt]?.reason);
7853
+ this[Ie] = true, this.emit("abort", this[Jt]?.reason), this.destroy(this[Jt]?.reason);
7854
7854
  }
7855
7855
  get aborted() {
7856
- return this[Ae];
7856
+ return this[Ie];
7857
7857
  }
7858
7858
  set aborted(t) {
7859
7859
  }
7860
7860
  write(t, e, i) {
7861
- if (this[Ae]) return false;
7861
+ if (this[Ie]) return false;
7862
7862
  if (this[q]) throw new Error("write after end");
7863
7863
  if (this[w]) return this.emit("error", Object.assign(new Error("Cannot call write after a stream was destroyed"), { code: "ERR_STREAM_DESTROYED" })), true;
7864
7864
  typeof e == "function" && (i = e, e = "utf8"), e || (e = "utf8");
7865
- let r = this[Z] ? te : vr;
7865
+ let r = this[Z] ? te : kr;
7866
7866
  if (!this[L] && !Buffer.isBuffer(t)) {
7867
- if (Pr(t)) t = Buffer.from(t.buffer, t.byteOffset, t.byteLength);
7868
- else if (Br(t)) t = Buffer.from(t);
7867
+ if (Br(t)) t = Buffer.from(t.buffer, t.byteOffset, t.byteLength);
7868
+ else if (Mr(t)) t = Buffer.from(t);
7869
7869
  else if (typeof t != "string") throw new Error("Non-contiguous data written to non-objectMode stream");
7870
7870
  }
7871
- return this[L] ? (this[b] && this[_] !== 0 && this[Ne](true), this[b] ? this.emit("data", t) : this[Si](t), this[_] !== 0 && this.emit("readable"), i && r(i), this[b]) : 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[b] && this[_] !== 0 && this[Ne](true), this[b] ? this.emit("data", t) : this[Si](t), this[_] !== 0 && this.emit("readable"), i && r(i), this[b]) : (this[_] !== 0 && this.emit("readable"), i && r(i), this[b]);
7871
+ return this[L] ? (this[b] && this[g] !== 0 && this[Ae](true), this[b] ? this.emit("data", t) : this[yi](t), this[g] !== 0 && this.emit("readable"), i && r(i), this[b]) : 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[b] && this[g] !== 0 && this[Ae](true), this[b] ? this.emit("data", t) : this[yi](t), this[g] !== 0 && this.emit("readable"), i && r(i), this[b]) : (this[g] !== 0 && this.emit("readable"), i && r(i), this[b]);
7872
7872
  }
7873
7873
  read(t) {
7874
7874
  if (this[w]) return null;
7875
- if (this[C] = false, this[_] === 0 || t === 0 || t && t > this[_]) return this[j](), null;
7876
- this[L] && (t = null), this[g].length > 1 && !this[L] && (this[g] = [this[z] ? this[g].join("") : Buffer.concat(this[g], this[_])]);
7877
- let e = this[xs](t || null, this[g][0]);
7875
+ if (this[C] = false, this[g] === 0 || t === 0 || t && t > this[g]) return this[j](), null;
7876
+ this[L] && (t = null), this[_].length > 1 && !this[L] && (this[_] = [this[z] ? this[_].join("") : Buffer.concat(this[_], this[g])]);
7877
+ let e = this[Ts](t || null, this[_][0]);
7878
7878
  return this[j](), e;
7879
7879
  }
7880
- [xs](t, e) {
7880
+ [Ts](t, e) {
7881
7881
  if (this[L]) this[De]();
7882
7882
  else {
7883
7883
  let i = e;
7884
- t === i.length || t === null ? this[De]() : typeof i == "string" ? (this[g][0] = i.slice(t), e = i.slice(0, t), this[_] -= t) : (this[g][0] = i.subarray(t), e = i.subarray(0, t), this[_] -= t);
7884
+ t === i.length || t === null ? this[De]() : typeof i == "string" ? (this[_][0] = i.slice(t), e = i.slice(0, t), this[g] -= t) : (this[_][0] = i.subarray(t), e = i.subarray(0, t), this[g] -= t);
7885
7885
  }
7886
- return this.emit("data", e), !this[g].length && !this[q] && this.emit("drain"), e;
7886
+ return this.emit("data", e), !this[_].length && !this[q] && this.emit("drain"), e;
7887
7887
  }
7888
7888
  end(t, e, i) {
7889
7889
  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[b] || !this[Qt]) && this[j](), this;
7890
7890
  }
7891
7891
  [Bt]() {
7892
- this[w] || (!this[yt] && !this[D].length && (this[C] = true), this[Qt] = false, this[b] = true, this.emit("resume"), this[g].length ? this[Ne]() : this[q] ? this[j]() : this.emit("drain"));
7892
+ this[w] || (!this[yt] && !this[A].length && (this[C] = true), this[Qt] = false, this[b] = true, this.emit("resume"), this[_].length ? this[Ae]() : this[q] ? this[j]() : this.emit("drain"));
7893
7893
  }
7894
7894
  resume() {
7895
7895
  return this[Bt]();
@@ -7906,39 +7906,39 @@ var A = class extends Oi {
7906
7906
  get paused() {
7907
7907
  return this[Qt];
7908
7908
  }
7909
- [Si](t) {
7910
- this[L] ? this[_] += 1 : this[_] += t.length, this[g].push(t);
7909
+ [yi](t) {
7910
+ this[L] ? this[g] += 1 : this[g] += t.length, this[_].push(t);
7911
7911
  }
7912
7912
  [De]() {
7913
- return this[L] ? this[_] -= 1 : this[_] -= this[g][0].length, this[g].shift();
7913
+ return this[L] ? this[g] -= 1 : this[g] -= this[_][0].length, this[_].shift();
7914
7914
  }
7915
- [Ne](t = false) {
7915
+ [Ae](t = false) {
7916
7916
  do
7917
7917
  ;
7918
- while (this[Ls](this[De]()) && this[g].length);
7919
- !t && !this[g].length && !this[q] && this.emit("drain");
7918
+ while (this[xs](this[De]()) && this[_].length);
7919
+ !t && !this[_].length && !this[q] && this.emit("drain");
7920
7920
  }
7921
- [Ls](t) {
7921
+ [xs](t) {
7922
7922
  return this.emit("data", t), this[b];
7923
7923
  }
7924
7924
  pipe(t, e) {
7925
7925
  if (this[w]) return t;
7926
7926
  this[C] = false;
7927
7927
  let i = this[rt];
7928
- return e = e || {}, t === Ts.stdout || t === Ts.stderr ? e.end = false : e.end = e.end !== false, e.proxyErrors = !!e.proxyErrors, i ? e.end && t.end() : (this[D].push(e.proxyErrors ? new _i(this, t, e) : new Ie(this, t, e)), this[Z] ? te(() => this[Bt]()) : this[Bt]()), t;
7928
+ return e = e || {}, t === Os.stdout || t === Os.stderr ? e.end = false : e.end = e.end !== false, e.proxyErrors = !!e.proxyErrors, i ? e.end && t.end() : (this[A].push(e.proxyErrors ? new Oi(this, t, e) : new Ce(this, t, e)), this[Z] ? te(() => this[Bt]()) : this[Bt]()), t;
7929
7929
  }
7930
7930
  unpipe(t) {
7931
- let e = this[D].find((i) => i.dest === t);
7932
- e && (this[D].length === 1 ? (this[b] && this[yt] === 0 && (this[b] = false), this[D] = []) : this[D].splice(this[D].indexOf(e), 1), e.unpipe());
7931
+ let e = this[A].find((i) => i.dest === t);
7932
+ e && (this[A].length === 1 ? (this[b] && this[yt] === 0 && (this[b] = false), this[A] = []) : this[A].splice(this[A].indexOf(e), 1), e.unpipe());
7933
7933
  }
7934
7934
  addListener(t, e) {
7935
7935
  return this.on(t, e);
7936
7936
  }
7937
7937
  on(t, e) {
7938
7938
  let i = super.on(t, e);
7939
- if (t === "data") this[C] = false, this[yt]++, !this[D].length && !this[b] && this[Bt]();
7940
- else if (t === "readable" && this[_] !== 0) super.emit("readable");
7941
- else if (Mr(t) && this[rt]) super.emit(t), this.removeAllListeners(t);
7939
+ if (t === "data") this[C] = false, this[yt]++, !this[A].length && !this[b] && this[Bt]();
7940
+ else if (t === "readable" && this[g] !== 0) super.emit("readable");
7941
+ else if (vr(t) && this[rt]) super.emit(t), this.removeAllListeners(t);
7942
7942
  else if (t === "error" && this[jt]) {
7943
7943
  let r = e;
7944
7944
  this[Z] ? te(() => r.call(this, this[jt])) : r.call(this, this[jt]);
@@ -7950,29 +7950,29 @@ var A = class extends Oi {
7950
7950
  }
7951
7951
  off(t, e) {
7952
7952
  let i = super.off(t, e);
7953
- return t === "data" && (this[yt] = this.listeners("data").length, this[yt] === 0 && !this[C] && !this[D].length && (this[b] = false)), i;
7953
+ return t === "data" && (this[yt] = this.listeners("data").length, this[yt] === 0 && !this[C] && !this[A].length && (this[b] = false)), i;
7954
7954
  }
7955
7955
  removeAllListeners(t) {
7956
7956
  let e = super.removeAllListeners(t);
7957
- return (t === "data" || t === void 0) && (this[yt] = 0, !this[C] && !this[D].length && (this[b] = false)), e;
7957
+ return (t === "data" || t === void 0) && (this[yt] = 0, !this[C] && !this[A].length && (this[b] = false)), e;
7958
7958
  }
7959
7959
  get emittedEnd() {
7960
7960
  return this[rt];
7961
7961
  }
7962
7962
  [j]() {
7963
- !this[xe] && !this[rt] && !this[w] && this[g].length === 0 && this[q] && (this[xe] = true, this.emit("end"), this.emit("prefinish"), this.emit("finish"), this[Le] && this.emit("close"), this[xe] = false);
7963
+ !this[Le] && !this[rt] && !this[w] && this[_].length === 0 && this[q] && (this[Le] = true, this.emit("end"), this.emit("prefinish"), this.emit("finish"), this[Ne] && this.emit("close"), this[Le] = false);
7964
7964
  }
7965
7965
  emit(t, ...e) {
7966
7966
  let i = e[0];
7967
7967
  if (t !== "error" && t !== "close" && t !== w && this[w]) return false;
7968
- if (t === "data") return !this[L] && !i ? false : this[Z] ? (te(() => this[Ri](i)), true) : this[Ri](i);
7969
- if (t === "end") return this[Ns]();
7968
+ if (t === "data") return !this[L] && !i ? false : this[Z] ? (te(() => this[bi](i)), true) : this[bi](i);
7969
+ if (t === "end") return this[Ls]();
7970
7970
  if (t === "close") {
7971
- if (this[Le] = true, !this[rt] && !this[w]) return false;
7971
+ if (this[Ne] = true, !this[rt] && !this[w]) return false;
7972
7972
  let n = super.emit("close");
7973
7973
  return this.removeAllListeners("close"), n;
7974
7974
  } else if (t === "error") {
7975
- this[jt] = i, super.emit(yi, i);
7975
+ this[jt] = i, super.emit(Ri, i);
7976
7976
  let n = !this[Jt] || this.listeners("error").length ? super.emit("error", i) : false;
7977
7977
  return this[j](), n;
7978
7978
  } else if (t === "resume") {
@@ -7985,23 +7985,23 @@ var A = class extends Oi {
7985
7985
  let r = super.emit(t, ...e);
7986
7986
  return this[j](), r;
7987
7987
  }
7988
- [Ri](t) {
7989
- for (let i of this[D]) i.dest.write(t) === false && this.pause();
7988
+ [bi](t) {
7989
+ for (let i of this[A]) i.dest.write(t) === false && this.pause();
7990
7990
  let e = this[C] ? false : super.emit("data", t);
7991
7991
  return this[j](), e;
7992
7992
  }
7993
- [Ns]() {
7994
- return this[rt] ? false : (this[rt] = true, this.readable = false, this[Z] ? (te(() => this[bi]()), true) : this[bi]());
7993
+ [Ls]() {
7994
+ return this[rt] ? false : (this[rt] = true, this.readable = false, this[Z] ? (te(() => this[_i]()), true) : this[_i]());
7995
7995
  }
7996
- [bi]() {
7996
+ [_i]() {
7997
7997
  if (this[Mt]) {
7998
7998
  let e = this[Mt].end();
7999
7999
  if (e) {
8000
- for (let i of this[D]) i.dest.write(e);
8000
+ for (let i of this[A]) i.dest.write(e);
8001
8001
  this[C] || super.emit("data", e);
8002
8002
  }
8003
8003
  }
8004
- for (let e of this[D]) e.end();
8004
+ for (let e of this[A]) e.end();
8005
8005
  let t = super.emit("end");
8006
8006
  return this.removeAllListeners("end"), t;
8007
8007
  }
@@ -8048,67 +8048,67 @@ var A = class extends Oi {
8048
8048
  }
8049
8049
  [Symbol.iterator]() {
8050
8050
  this[C] = false;
8051
- let t = false, e = () => (this.pause(), this.off(yi, e), this.off(w, e), this.off("end", e), t = true, { done: true, value: void 0 }), i = () => {
8051
+ let t = false, e = () => (this.pause(), this.off(Ri, e), this.off(w, e), this.off("end", e), t = true, { done: true, value: void 0 }), i = () => {
8052
8052
  if (t) return e();
8053
8053
  let r = this.read();
8054
8054
  return r === null ? e() : { done: false, value: r };
8055
8055
  };
8056
- return this.once("end", e), this.once(yi, e), this.once(w, e), { next: i, throw: e, return: e, [Symbol.iterator]() {
8056
+ return this.once("end", e), this.once(Ri, e), this.once(w, e), { next: i, throw: e, return: e, [Symbol.iterator]() {
8057
8057
  return this;
8058
8058
  }, [Symbol.dispose]: () => {
8059
8059
  } };
8060
8060
  }
8061
8061
  destroy(t) {
8062
8062
  if (this[w]) return t ? this.emit("error", t) : this.emit(w), this;
8063
- this[w] = true, this[C] = true, this[g].length = 0, this[_] = 0;
8063
+ this[w] = true, this[C] = true, this[_].length = 0, this[g] = 0;
8064
8064
  let e = this;
8065
- return typeof e.close == "function" && !this[Le] && e.close(), t ? this.emit("error", t) : this.emit(w), this;
8065
+ return typeof e.close == "function" && !this[Ne] && e.close(), t ? this.emit("error", t) : this.emit(w), this;
8066
8066
  }
8067
8067
  static get isStream() {
8068
- return Cr;
8068
+ return Ir;
8069
8069
  }
8070
8070
  };
8071
- var Wr = I.writev;
8071
+ var Hr = I.writev;
8072
8072
  var ot = /* @__PURE__ */ Symbol("_autoClose");
8073
8073
  var H = /* @__PURE__ */ Symbol("_close");
8074
8074
  var ee = /* @__PURE__ */ Symbol("_ended");
8075
8075
  var m = /* @__PURE__ */ Symbol("_fd");
8076
- var Ti = /* @__PURE__ */ Symbol("_finished");
8076
+ var xi = /* @__PURE__ */ Symbol("_finished");
8077
8077
  var J = /* @__PURE__ */ Symbol("_flags");
8078
- var xi = /* @__PURE__ */ Symbol("_flush");
8079
- var Ai = /* @__PURE__ */ Symbol("_handleChunk");
8080
- var Ii = /* @__PURE__ */ Symbol("_makeBuf");
8078
+ var Li = /* @__PURE__ */ Symbol("_flush");
8079
+ var Ii = /* @__PURE__ */ Symbol("_handleChunk");
8080
+ var Ci = /* @__PURE__ */ Symbol("_makeBuf");
8081
8081
  var se = /* @__PURE__ */ Symbol("_mode");
8082
- var Ce = /* @__PURE__ */ Symbol("_needDrain");
8082
+ var Fe = /* @__PURE__ */ Symbol("_needDrain");
8083
8083
  var Ut = /* @__PURE__ */ Symbol("_onerror");
8084
8084
  var Ht = /* @__PURE__ */ Symbol("_onopen");
8085
- var Li = /* @__PURE__ */ Symbol("_onread");
8085
+ var Ni = /* @__PURE__ */ Symbol("_onread");
8086
8086
  var Pt = /* @__PURE__ */ Symbol("_onwrite");
8087
8087
  var ht = /* @__PURE__ */ Symbol("_open");
8088
8088
  var U = /* @__PURE__ */ Symbol("_path");
8089
8089
  var nt = /* @__PURE__ */ Symbol("_pos");
8090
8090
  var Y = /* @__PURE__ */ Symbol("_queue");
8091
8091
  var zt = /* @__PURE__ */ Symbol("_read");
8092
- var Ni = /* @__PURE__ */ Symbol("_readSize");
8092
+ var Ai = /* @__PURE__ */ Symbol("_readSize");
8093
8093
  var Q = /* @__PURE__ */ Symbol("_reading");
8094
8094
  var ie = /* @__PURE__ */ Symbol("_remain");
8095
8095
  var Di = /* @__PURE__ */ Symbol("_size");
8096
- var Fe = /* @__PURE__ */ Symbol("_write");
8096
+ var ke = /* @__PURE__ */ Symbol("_write");
8097
8097
  var Rt = /* @__PURE__ */ Symbol("_writing");
8098
- var ke = /* @__PURE__ */ Symbol("_defaultFlag");
8098
+ var ve = /* @__PURE__ */ Symbol("_defaultFlag");
8099
8099
  var bt = /* @__PURE__ */ Symbol("_errored");
8100
- var gt = class extends A {
8100
+ var _t = class extends D {
8101
8101
  [bt] = false;
8102
8102
  [m];
8103
8103
  [U];
8104
- [Ni];
8104
+ [Ai];
8105
8105
  [Q] = false;
8106
8106
  [Di];
8107
8107
  [ie];
8108
8108
  [ot];
8109
8109
  constructor(t, e) {
8110
8110
  if (e = e || {}, super(e), this.readable = true, this.writable = false, typeof t != "string") throw new TypeError("path must be a string");
8111
- this[bt] = false, this[m] = typeof e.fd == "number" ? e.fd : void 0, this[U] = t, this[Ni] = e.readSize || 16 * 1024 * 1024, this[Q] = false, this[Di] = typeof e.size == "number" ? e.size : 1 / 0, this[ie] = this[Di], this[ot] = typeof e.autoClose == "boolean" ? e.autoClose : true, typeof this[m] == "number" ? this[zt]() : this[ht]();
8111
+ this[bt] = false, this[m] = typeof e.fd == "number" ? e.fd : void 0, this[U] = t, this[Ai] = e.readSize || 16 * 1024 * 1024, this[Q] = false, this[Di] = typeof e.size == "number" ? e.size : 1 / 0, this[ie] = this[Di], this[ot] = typeof e.autoClose == "boolean" ? e.autoClose : true, typeof this[m] == "number" ? this[zt]() : this[ht]();
8112
8112
  }
8113
8113
  get fd() {
8114
8114
  return this[m];
@@ -8128,19 +8128,19 @@ var gt = class extends A {
8128
8128
  [Ht](t, e) {
8129
8129
  t ? this[Ut](t) : (this[m] = e, this.emit("open", e), this[zt]());
8130
8130
  }
8131
- [Ii]() {
8132
- return Buffer.allocUnsafe(Math.min(this[Ni], this[ie]));
8131
+ [Ci]() {
8132
+ return Buffer.allocUnsafe(Math.min(this[Ai], this[ie]));
8133
8133
  }
8134
8134
  [zt]() {
8135
8135
  if (!this[Q]) {
8136
8136
  this[Q] = true;
8137
- let t = this[Ii]();
8138
- if (t.length === 0) return process.nextTick(() => this[Li](null, 0, t));
8139
- I.read(this[m], t, 0, t.length, null, (e, i, r) => this[Li](e, i, r));
8137
+ let t = this[Ci]();
8138
+ if (t.length === 0) return process.nextTick(() => this[Ni](null, 0, t));
8139
+ I.read(this[m], t, 0, t.length, null, (e, i, r) => this[Ni](e, i, r));
8140
8140
  }
8141
8141
  }
8142
- [Li](t, e, i) {
8143
- this[Q] = false, t ? this[Ut](t) : this[Ai](e, i) && this[zt]();
8142
+ [Ni](t, e, i) {
8143
+ this[Q] = false, t ? this[Ut](t) : this[Ii](e, i) && this[zt]();
8144
8144
  }
8145
8145
  [H]() {
8146
8146
  if (this[ot] && typeof this[m] == "number") {
@@ -8151,7 +8151,7 @@ var gt = class extends A {
8151
8151
  [Ut](t) {
8152
8152
  this[Q] = true, this[H](), this.emit("error", t);
8153
8153
  }
8154
- [Ai](t, e) {
8154
+ [Ii](t, e) {
8155
8155
  let i = false;
8156
8156
  return this[ie] -= t, t > 0 && (i = super.write(t < e.length ? e.subarray(0, t) : e)), (t === 0 || this[ie] <= 0) && (i = false, this[H](), super.end()), i;
8157
8157
  }
@@ -8169,7 +8169,7 @@ var gt = class extends A {
8169
8169
  }
8170
8170
  }
8171
8171
  };
8172
- var ve = class extends gt {
8172
+ var Me = class extends _t {
8173
8173
  [ht]() {
8174
8174
  let t = true;
8175
8175
  try {
@@ -8184,8 +8184,8 @@ var ve = class extends gt {
8184
8184
  if (!this[Q]) {
8185
8185
  this[Q] = true;
8186
8186
  do {
8187
- let e = this[Ii](), i = e.length === 0 ? 0 : I.readSync(this[m], e, 0, e.length, null);
8188
- if (!this[Ai](i, e)) break;
8187
+ let e = this[Ci](), i = e.length === 0 ? 0 : I.readSync(this[m], e, 0, e.length, null);
8188
+ if (!this[Ii](i, e)) break;
8189
8189
  } while (true);
8190
8190
  this[Q] = false;
8191
8191
  }
@@ -8201,26 +8201,26 @@ var ve = class extends gt {
8201
8201
  }
8202
8202
  }
8203
8203
  };
8204
- var tt2 = class extends Hr {
8204
+ var tt2 = class extends Ur {
8205
8205
  readable = false;
8206
8206
  writable = true;
8207
8207
  [bt] = false;
8208
8208
  [Rt] = false;
8209
8209
  [ee] = false;
8210
8210
  [Y] = [];
8211
- [Ce] = false;
8211
+ [Fe] = false;
8212
8212
  [U];
8213
8213
  [se];
8214
8214
  [ot];
8215
8215
  [m];
8216
- [ke];
8216
+ [ve];
8217
8217
  [J];
8218
- [Ti] = false;
8218
+ [xi] = false;
8219
8219
  [nt];
8220
8220
  constructor(t, e) {
8221
8221
  e = e || {}, super(e), this[U] = t, this[m] = typeof e.fd == "number" ? e.fd : void 0, this[se] = e.mode === void 0 ? 438 : e.mode, this[nt] = typeof e.start == "number" ? e.start : void 0, this[ot] = typeof e.autoClose == "boolean" ? e.autoClose : true;
8222
8222
  let i = this[nt] !== void 0 ? "r+" : "w";
8223
- this[ke] = e.flags === void 0, this[J] = e.flags === void 0 ? i : e.flags, this[m] === void 0 && this[ht]();
8223
+ this[ve] = e.flags === void 0, this[J] = e.flags === void 0 ? i : e.flags, this[m] === void 0 && this[ht]();
8224
8224
  }
8225
8225
  emit(t, ...e) {
8226
8226
  if (t === "error") {
@@ -8242,26 +8242,26 @@ var tt2 = class extends Hr {
8242
8242
  I.open(this[U], this[J], this[se], (t, e) => this[Ht](t, e));
8243
8243
  }
8244
8244
  [Ht](t, e) {
8245
- this[ke] && this[J] === "r+" && t && t.code === "ENOENT" ? (this[J] = "w", this[ht]()) : t ? this[Ut](t) : (this[m] = e, this.emit("open", e), this[Rt] || this[xi]());
8245
+ this[ve] && this[J] === "r+" && t && t.code === "ENOENT" ? (this[J] = "w", this[ht]()) : t ? this[Ut](t) : (this[m] = e, this.emit("open", e), this[Rt] || this[Li]());
8246
8246
  }
8247
8247
  end(t, e) {
8248
8248
  return t && this.write(t, e), this[ee] = true, !this[Rt] && !this[Y].length && typeof this[m] == "number" && this[Pt](null, 0), this;
8249
8249
  }
8250
8250
  write(t, e) {
8251
- return typeof t == "string" && (t = Buffer.from(t, e)), this[ee] ? (this.emit("error", new Error("write() after end()")), false) : this[m] === void 0 || this[Rt] || this[Y].length ? (this[Y].push(t), this[Ce] = true, false) : (this[Rt] = true, this[Fe](t), true);
8251
+ return typeof t == "string" && (t = Buffer.from(t, e)), this[ee] ? (this.emit("error", new Error("write() after end()")), false) : this[m] === void 0 || this[Rt] || this[Y].length ? (this[Y].push(t), this[Fe] = true, false) : (this[Rt] = true, this[ke](t), true);
8252
8252
  }
8253
- [Fe](t) {
8253
+ [ke](t) {
8254
8254
  I.write(this[m], t, 0, t.length, this[nt], (e, i) => this[Pt](e, i));
8255
8255
  }
8256
8256
  [Pt](t, e) {
8257
- t ? this[Ut](t) : (this[nt] !== void 0 && typeof e == "number" && (this[nt] += e), this[Y].length ? this[xi]() : (this[Rt] = false, this[ee] && !this[Ti] ? (this[Ti] = true, this[H](), this.emit("finish")) : this[Ce] && (this[Ce] = false, this.emit("drain"))));
8257
+ t ? this[Ut](t) : (this[nt] !== void 0 && typeof e == "number" && (this[nt] += e), this[Y].length ? this[Li]() : (this[Rt] = false, this[ee] && !this[xi] ? (this[xi] = true, this[H](), this.emit("finish")) : this[Fe] && (this[Fe] = false, this.emit("drain"))));
8258
8258
  }
8259
- [xi]() {
8259
+ [Li]() {
8260
8260
  if (this[Y].length === 0) this[ee] && this[Pt](null, 0);
8261
- else if (this[Y].length === 1) this[Fe](this[Y].pop());
8261
+ else if (this[Y].length === 1) this[ke](this[Y].pop());
8262
8262
  else {
8263
8263
  let t = this[Y];
8264
- this[Y] = [], Wr(this[m], t, this[nt], (e, i) => this[Pt](e, i));
8264
+ this[Y] = [], Hr(this[m], t, this[nt], (e, i) => this[Pt](e, i));
8265
8265
  }
8266
8266
  }
8267
8267
  [H]() {
@@ -8274,7 +8274,7 @@ var tt2 = class extends Hr {
8274
8274
  var Wt = class extends tt2 {
8275
8275
  [ht]() {
8276
8276
  let t;
8277
- if (this[ke] && this[J] === "r+") try {
8277
+ if (this[ve] && this[J] === "r+") try {
8278
8278
  t = I.openSync(this[U], this[J], this[se]);
8279
8279
  } catch (e) {
8280
8280
  if (e?.code === "ENOENT") return this[J] = "w", this[ht]();
@@ -8289,7 +8289,7 @@ var Wt = class extends tt2 {
8289
8289
  this[m] = void 0, I.closeSync(t), this.emit("close");
8290
8290
  }
8291
8291
  }
8292
- [Fe](t) {
8292
+ [ke](t) {
8293
8293
  let e = true;
8294
8294
  try {
8295
8295
  this[Pt](null, I.writeSync(this[m], t, 0, t.length, this[nt])), e = false;
@@ -8301,49 +8301,50 @@ var Wt = class extends tt2 {
8301
8301
  }
8302
8302
  }
8303
8303
  };
8304
- var Gr = /* @__PURE__ */ new Map([["C", "cwd"], ["f", "file"], ["z", "gzip"], ["P", "preservePaths"], ["U", "unlink"], ["strip-components", "strip"], ["stripComponents", "strip"], ["keep-newer", "newer"], ["keepNewer", "newer"], ["keep-newer-files", "newer"], ["keepNewerFiles", "newer"], ["k", "keep"], ["keep-existing", "keep"], ["keepExisting", "keep"], ["m", "noMtime"], ["no-mtime", "noMtime"], ["p", "preserveOwner"], ["L", "follow"], ["h", "follow"], ["onentry", "onReadEntry"]]);
8304
+ var Wr = /* @__PURE__ */ new Map([["C", "cwd"], ["f", "file"], ["z", "gzip"], ["P", "preservePaths"], ["U", "unlink"], ["strip-components", "strip"], ["stripComponents", "strip"], ["keep-newer", "newer"], ["keepNewer", "newer"], ["keep-newer-files", "newer"], ["keepNewerFiles", "newer"], ["k", "keep"], ["keep-existing", "keep"], ["keepExisting", "keep"], ["m", "noMtime"], ["no-mtime", "noMtime"], ["p", "preserveOwner"], ["L", "follow"], ["h", "follow"], ["onentry", "onReadEntry"]]);
8305
8305
  var As = (s3) => !!s3.sync && !!s3.file;
8306
- var Is = (s3) => !s3.sync && !!s3.file;
8307
- var Cs = (s3) => !!s3.sync && !s3.file;
8308
- var Fs = (s3) => !s3.sync && !s3.file;
8309
- var ks = (s3) => !!s3.file;
8310
- var Zr = (s3) => {
8311
- let t = Gr.get(s3);
8306
+ var Ds = (s3) => !s3.sync && !!s3.file;
8307
+ var Is = (s3) => !!s3.sync && !s3.file;
8308
+ var Cs = (s3) => !s3.sync && !s3.file;
8309
+ var Fs = (s3) => !!s3.file;
8310
+ var Gr = (s3) => {
8311
+ let t = Wr.get(s3);
8312
8312
  return t || s3;
8313
8313
  };
8314
8314
  var re = (s3 = {}) => {
8315
8315
  if (!s3) return {};
8316
8316
  let t = {};
8317
8317
  for (let [e, i] of Object.entries(s3)) {
8318
- let r = Zr(e);
8318
+ let r = Gr(e);
8319
8319
  t[r] = i;
8320
8320
  }
8321
8321
  return t.chmod === void 0 && t.noChmod === false && (t.chmod = true), delete t.noChmod, t;
8322
8322
  };
8323
8323
  var K = (s3, t, e, i, r) => Object.assign((n = [], o, h) => {
8324
- Array.isArray(n) && (o = n, n = {}), typeof o == "function" && (h = o, o = void 0), o ? o = Array.from(o) : o = [];
8324
+ Array.isArray(n) && (o = n, n = {}), typeof o == "function" && (h = o, o = void 0), o = o ? Array.from(o) : [];
8325
8325
  let a = re(n);
8326
8326
  if (r?.(a, o), As(a)) {
8327
8327
  if (typeof h == "function") throw new TypeError("callback not supported for sync tar functions");
8328
8328
  return s3(a, o);
8329
+ } else if (Ds(a)) {
8330
+ let l = t(a, o);
8331
+ return h ? l.then(() => h(), h) : l;
8329
8332
  } else if (Is(a)) {
8330
- let l = t(a, o), c = h || void 0;
8331
- return c ? l.then(() => c(), c) : l;
8332
- } else if (Cs(a)) {
8333
8333
  if (typeof h == "function") throw new TypeError("callback not supported for sync tar functions");
8334
8334
  return e(a, o);
8335
- } else if (Fs(a)) {
8335
+ } else if (Cs(a)) {
8336
8336
  if (typeof h == "function") throw new TypeError("callback only supported with file option");
8337
8337
  return i(a, o);
8338
- } else throw new Error("impossible options??");
8338
+ }
8339
+ throw new Error("impossible options??");
8339
8340
  }, { syncFile: s3, asyncFile: t, syncNoFile: e, asyncNoFile: i, validate: r });
8340
- var Kr = Yr.constants || { ZLIB_VERNUM: 4736 };
8341
- var M = Object.freeze(Object.assign(/* @__PURE__ */ Object.create(null), { Z_NO_FLUSH: 0, Z_PARTIAL_FLUSH: 1, Z_SYNC_FLUSH: 2, Z_FULL_FLUSH: 3, Z_FINISH: 4, Z_BLOCK: 5, Z_OK: 0, Z_STREAM_END: 1, Z_NEED_DICT: 2, Z_ERRNO: -1, Z_STREAM_ERROR: -2, Z_DATA_ERROR: -3, Z_MEM_ERROR: -4, Z_BUF_ERROR: -5, Z_VERSION_ERROR: -6, Z_NO_COMPRESSION: 0, Z_BEST_SPEED: 1, Z_BEST_COMPRESSION: 9, Z_DEFAULT_COMPRESSION: -1, Z_FILTERED: 1, Z_HUFFMAN_ONLY: 2, Z_RLE: 3, Z_FIXED: 4, Z_DEFAULT_STRATEGY: 0, DEFLATE: 1, INFLATE: 2, GZIP: 3, GUNZIP: 4, DEFLATERAW: 5, INFLATERAW: 6, UNZIP: 7, BROTLI_DECODE: 8, BROTLI_ENCODE: 9, Z_MIN_WINDOWBITS: 8, Z_MAX_WINDOWBITS: 15, Z_DEFAULT_WINDOWBITS: 15, Z_MIN_CHUNK: 64, Z_MAX_CHUNK: 1 / 0, Z_DEFAULT_CHUNK: 16384, Z_MIN_MEMLEVEL: 1, Z_MAX_MEMLEVEL: 9, Z_DEFAULT_MEMLEVEL: 8, Z_MIN_LEVEL: -1, Z_MAX_LEVEL: 9, Z_DEFAULT_LEVEL: -1, BROTLI_OPERATION_PROCESS: 0, BROTLI_OPERATION_FLUSH: 1, BROTLI_OPERATION_FINISH: 2, BROTLI_OPERATION_EMIT_METADATA: 3, BROTLI_MODE_GENERIC: 0, BROTLI_MODE_TEXT: 1, BROTLI_MODE_FONT: 2, BROTLI_DEFAULT_MODE: 0, BROTLI_MIN_QUALITY: 0, BROTLI_MAX_QUALITY: 11, BROTLI_DEFAULT_QUALITY: 11, BROTLI_MIN_WINDOW_BITS: 10, BROTLI_MAX_WINDOW_BITS: 24, BROTLI_LARGE_MAX_WINDOW_BITS: 30, BROTLI_DEFAULT_WINDOW: 22, BROTLI_MIN_INPUT_BLOCK_BITS: 16, BROTLI_MAX_INPUT_BLOCK_BITS: 24, BROTLI_PARAM_MODE: 0, BROTLI_PARAM_QUALITY: 1, BROTLI_PARAM_LGWIN: 2, BROTLI_PARAM_LGBLOCK: 3, BROTLI_PARAM_DISABLE_LITERAL_CONTEXT_MODELING: 4, BROTLI_PARAM_SIZE_HINT: 5, BROTLI_PARAM_LARGE_WINDOW: 6, BROTLI_PARAM_NPOSTFIX: 7, BROTLI_PARAM_NDIRECT: 8, BROTLI_DECODER_RESULT_ERROR: 0, BROTLI_DECODER_RESULT_SUCCESS: 1, BROTLI_DECODER_RESULT_NEEDS_MORE_INPUT: 2, BROTLI_DECODER_RESULT_NEEDS_MORE_OUTPUT: 3, BROTLI_DECODER_PARAM_DISABLE_RING_BUFFER_REALLOCATION: 0, BROTLI_DECODER_PARAM_LARGE_WINDOW: 1, BROTLI_DECODER_NO_ERROR: 0, BROTLI_DECODER_SUCCESS: 1, BROTLI_DECODER_NEEDS_MORE_INPUT: 2, BROTLI_DECODER_NEEDS_MORE_OUTPUT: 3, BROTLI_DECODER_ERROR_FORMAT_EXUBERANT_NIBBLE: -1, BROTLI_DECODER_ERROR_FORMAT_RESERVED: -2, BROTLI_DECODER_ERROR_FORMAT_EXUBERANT_META_NIBBLE: -3, BROTLI_DECODER_ERROR_FORMAT_SIMPLE_HUFFMAN_ALPHABET: -4, BROTLI_DECODER_ERROR_FORMAT_SIMPLE_HUFFMAN_SAME: -5, BROTLI_DECODER_ERROR_FORMAT_CL_SPACE: -6, BROTLI_DECODER_ERROR_FORMAT_HUFFMAN_SPACE: -7, BROTLI_DECODER_ERROR_FORMAT_CONTEXT_MAP_REPEAT: -8, BROTLI_DECODER_ERROR_FORMAT_BLOCK_LENGTH_1: -9, BROTLI_DECODER_ERROR_FORMAT_BLOCK_LENGTH_2: -10, BROTLI_DECODER_ERROR_FORMAT_TRANSFORM: -11, BROTLI_DECODER_ERROR_FORMAT_DICTIONARY: -12, BROTLI_DECODER_ERROR_FORMAT_WINDOW_BITS: -13, BROTLI_DECODER_ERROR_FORMAT_PADDING_1: -14, BROTLI_DECODER_ERROR_FORMAT_PADDING_2: -15, BROTLI_DECODER_ERROR_FORMAT_DISTANCE: -16, BROTLI_DECODER_ERROR_DICTIONARY_NOT_SET: -19, BROTLI_DECODER_ERROR_INVALID_ARGUMENTS: -20, BROTLI_DECODER_ERROR_ALLOC_CONTEXT_MODES: -21, BROTLI_DECODER_ERROR_ALLOC_TREE_GROUPS: -22, BROTLI_DECODER_ERROR_ALLOC_CONTEXT_MAP: -25, BROTLI_DECODER_ERROR_ALLOC_RING_BUFFER_1: -26, BROTLI_DECODER_ERROR_ALLOC_RING_BUFFER_2: -27, BROTLI_DECODER_ERROR_ALLOC_BLOCK_TYPE_TREES: -30, BROTLI_DECODER_ERROR_UNREACHABLE: -31 }, Kr));
8342
- var Vr = _t.concat;
8343
- var Ms = Object.getOwnPropertyDescriptor(_t, "concat");
8344
- var $r = (s3) => s3;
8345
- var Fi = Ms?.writable === true || Ms?.set !== void 0 ? (s3) => {
8346
- _t.concat = s3 ? $r : Vr;
8341
+ var Yr = Zr.constants || { ZLIB_VERNUM: 4736 };
8342
+ var M = Object.freeze(Object.assign(/* @__PURE__ */ Object.create(null), { Z_NO_FLUSH: 0, Z_PARTIAL_FLUSH: 1, Z_SYNC_FLUSH: 2, Z_FULL_FLUSH: 3, Z_FINISH: 4, Z_BLOCK: 5, Z_OK: 0, Z_STREAM_END: 1, Z_NEED_DICT: 2, Z_ERRNO: -1, Z_STREAM_ERROR: -2, Z_DATA_ERROR: -3, Z_MEM_ERROR: -4, Z_BUF_ERROR: -5, Z_VERSION_ERROR: -6, Z_NO_COMPRESSION: 0, Z_BEST_SPEED: 1, Z_BEST_COMPRESSION: 9, Z_DEFAULT_COMPRESSION: -1, Z_FILTERED: 1, Z_HUFFMAN_ONLY: 2, Z_RLE: 3, Z_FIXED: 4, Z_DEFAULT_STRATEGY: 0, DEFLATE: 1, INFLATE: 2, GZIP: 3, GUNZIP: 4, DEFLATERAW: 5, INFLATERAW: 6, UNZIP: 7, BROTLI_DECODE: 8, BROTLI_ENCODE: 9, Z_MIN_WINDOWBITS: 8, Z_MAX_WINDOWBITS: 15, Z_DEFAULT_WINDOWBITS: 15, Z_MIN_CHUNK: 64, Z_MAX_CHUNK: 1 / 0, Z_DEFAULT_CHUNK: 16384, Z_MIN_MEMLEVEL: 1, Z_MAX_MEMLEVEL: 9, Z_DEFAULT_MEMLEVEL: 8, Z_MIN_LEVEL: -1, Z_MAX_LEVEL: 9, Z_DEFAULT_LEVEL: -1, BROTLI_OPERATION_PROCESS: 0, BROTLI_OPERATION_FLUSH: 1, BROTLI_OPERATION_FINISH: 2, BROTLI_OPERATION_EMIT_METADATA: 3, BROTLI_MODE_GENERIC: 0, BROTLI_MODE_TEXT: 1, BROTLI_MODE_FONT: 2, BROTLI_DEFAULT_MODE: 0, BROTLI_MIN_QUALITY: 0, BROTLI_MAX_QUALITY: 11, BROTLI_DEFAULT_QUALITY: 11, BROTLI_MIN_WINDOW_BITS: 10, BROTLI_MAX_WINDOW_BITS: 24, BROTLI_LARGE_MAX_WINDOW_BITS: 30, BROTLI_DEFAULT_WINDOW: 22, BROTLI_MIN_INPUT_BLOCK_BITS: 16, BROTLI_MAX_INPUT_BLOCK_BITS: 24, BROTLI_PARAM_MODE: 0, BROTLI_PARAM_QUALITY: 1, BROTLI_PARAM_LGWIN: 2, BROTLI_PARAM_LGBLOCK: 3, BROTLI_PARAM_DISABLE_LITERAL_CONTEXT_MODELING: 4, BROTLI_PARAM_SIZE_HINT: 5, BROTLI_PARAM_LARGE_WINDOW: 6, BROTLI_PARAM_NPOSTFIX: 7, BROTLI_PARAM_NDIRECT: 8, BROTLI_DECODER_RESULT_ERROR: 0, BROTLI_DECODER_RESULT_SUCCESS: 1, BROTLI_DECODER_RESULT_NEEDS_MORE_INPUT: 2, BROTLI_DECODER_RESULT_NEEDS_MORE_OUTPUT: 3, BROTLI_DECODER_PARAM_DISABLE_RING_BUFFER_REALLOCATION: 0, BROTLI_DECODER_PARAM_LARGE_WINDOW: 1, BROTLI_DECODER_NO_ERROR: 0, BROTLI_DECODER_SUCCESS: 1, BROTLI_DECODER_NEEDS_MORE_INPUT: 2, BROTLI_DECODER_NEEDS_MORE_OUTPUT: 3, BROTLI_DECODER_ERROR_FORMAT_EXUBERANT_NIBBLE: -1, BROTLI_DECODER_ERROR_FORMAT_RESERVED: -2, BROTLI_DECODER_ERROR_FORMAT_EXUBERANT_META_NIBBLE: -3, BROTLI_DECODER_ERROR_FORMAT_SIMPLE_HUFFMAN_ALPHABET: -4, BROTLI_DECODER_ERROR_FORMAT_SIMPLE_HUFFMAN_SAME: -5, BROTLI_DECODER_ERROR_FORMAT_CL_SPACE: -6, BROTLI_DECODER_ERROR_FORMAT_HUFFMAN_SPACE: -7, BROTLI_DECODER_ERROR_FORMAT_CONTEXT_MAP_REPEAT: -8, BROTLI_DECODER_ERROR_FORMAT_BLOCK_LENGTH_1: -9, BROTLI_DECODER_ERROR_FORMAT_BLOCK_LENGTH_2: -10, BROTLI_DECODER_ERROR_FORMAT_TRANSFORM: -11, BROTLI_DECODER_ERROR_FORMAT_DICTIONARY: -12, BROTLI_DECODER_ERROR_FORMAT_WINDOW_BITS: -13, BROTLI_DECODER_ERROR_FORMAT_PADDING_1: -14, BROTLI_DECODER_ERROR_FORMAT_PADDING_2: -15, BROTLI_DECODER_ERROR_FORMAT_DISTANCE: -16, BROTLI_DECODER_ERROR_DICTIONARY_NOT_SET: -19, BROTLI_DECODER_ERROR_INVALID_ARGUMENTS: -20, BROTLI_DECODER_ERROR_ALLOC_CONTEXT_MODES: -21, BROTLI_DECODER_ERROR_ALLOC_TREE_GROUPS: -22, BROTLI_DECODER_ERROR_ALLOC_CONTEXT_MAP: -25, BROTLI_DECODER_ERROR_ALLOC_RING_BUFFER_1: -26, BROTLI_DECODER_ERROR_ALLOC_RING_BUFFER_2: -27, BROTLI_DECODER_ERROR_ALLOC_BLOCK_TYPE_TREES: -30, BROTLI_DECODER_ERROR_UNREACHABLE: -31 }, Yr));
8343
+ var Kr = gt.concat;
8344
+ var vs = Object.getOwnPropertyDescriptor(gt, "concat");
8345
+ var Vr = (s3) => s3;
8346
+ var ki = vs?.writable === true || vs?.set !== void 0 ? (s3) => {
8347
+ gt.concat = s3 ? Vr : Kr;
8347
8348
  } : (s3) => {
8348
8349
  };
8349
8350
  var Ot = /* @__PURE__ */ Symbol("_superWrite");
@@ -8357,8 +8358,8 @@ var Gt = class extends Error {
8357
8358
  return "ZlibError";
8358
8359
  }
8359
8360
  };
8360
- var ki = /* @__PURE__ */ Symbol("flushFlag");
8361
- var ne = class extends A {
8361
+ var vi = /* @__PURE__ */ Symbol("flushFlag");
8362
+ var ne = class extends D {
8362
8363
  #t = false;
8363
8364
  #i = false;
8364
8365
  #s;
@@ -8377,9 +8378,9 @@ var ne = class extends A {
8377
8378
  }
8378
8379
  constructor(t, e) {
8379
8380
  if (!t || typeof t != "object") throw new TypeError("invalid options for ZlibBase constructor");
8380
- if (super(t), this.#s = t.flush ?? 0, this.#n = t.finishFlush ?? 0, this.#r = t.fullFlushFlag ?? 0, typeof vs[e] != "function") throw new TypeError("Compression method not supported: " + e);
8381
+ if (super(t), this.#s = t.flush ?? 0, this.#n = t.finishFlush ?? 0, this.#r = t.fullFlushFlag ?? 0, typeof ks[e] != "function") throw new TypeError("Compression method not supported: " + e);
8381
8382
  try {
8382
- this.#e = new vs[e](t);
8383
+ this.#e = new ks[e](t);
8383
8384
  } catch (i) {
8384
8385
  throw new Gt(i, this.constructor);
8385
8386
  }
@@ -8391,10 +8392,10 @@ var ne = class extends A {
8391
8392
  this.#e && (this.#e.close(), this.#e = void 0, this.emit("close"));
8392
8393
  }
8393
8394
  reset() {
8394
- if (!this.#t) return vi(this.#e, "zlib binding closed"), this.#e.reset?.();
8395
+ if (!this.#t) return Mi(this.#e, "zlib binding closed"), this.#e.reset?.();
8395
8396
  }
8396
8397
  flush(t) {
8397
- this.ended || (typeof t != "number" && (t = this.#r), this.write(Object.assign(_t.alloc(0), { [ki]: t })));
8398
+ this.ended || (typeof t != "number" && (t = this.#r), this.write(Object.assign(gt.alloc(0), { [vi]: t })));
8398
8399
  }
8399
8400
  end(t, e, i) {
8400
8401
  return typeof t == "function" && (i = t, e = void 0, t = void 0), typeof e == "function" && (i = e, e = void 0), t && (e ? this.write(t, e) : this.write(t)), this.flush(this.#n), this.#i = true, super.end(i);
@@ -8406,20 +8407,20 @@ var ne = class extends A {
8406
8407
  return super.write(t);
8407
8408
  }
8408
8409
  write(t, e, i) {
8409
- if (typeof e == "function" && (i = e, e = "utf8"), typeof t == "string" && (t = _t.from(t, e)), this.#t) return;
8410
- vi(this.#e, "zlib binding closed");
8410
+ if (typeof e == "function" && (i = e, e = "utf8"), typeof t == "string" && (t = gt.from(t, e)), this.#t) return;
8411
+ Mi(this.#e, "zlib binding closed");
8411
8412
  let r = this.#e._handle, n = r.close;
8412
8413
  r.close = () => {
8413
8414
  };
8414
8415
  let o = this.#e.close;
8415
8416
  this.#e.close = () => {
8416
- }, Fi(true);
8417
+ }, ki(true);
8417
8418
  let h;
8418
8419
  try {
8419
- let l = typeof t[ki] == "number" ? t[ki] : this.#s;
8420
- h = this.#e._processChunk(t, l), Fi(false);
8420
+ let l = typeof t[vi] == "number" ? t[vi] : this.#s;
8421
+ h = this.#e._processChunk(t, l), ki(false);
8421
8422
  } catch (l) {
8422
- Fi(false), this.#o(new Gt(l, this.write));
8423
+ ki(false), this.#o(new Gt(l, this.write));
8423
8424
  } finally {
8424
8425
  this.#e && (this.#e._handle = r, r.close = n, this.#e.close = o, this.#e.removeAllListeners("error"));
8425
8426
  }
@@ -8427,13 +8428,13 @@ var ne = class extends A {
8427
8428
  let a;
8428
8429
  if (h) if (Array.isArray(h) && h.length > 0) {
8429
8430
  let l = h[0];
8430
- a = this[Ot](_t.from(l));
8431
+ a = this[Ot](gt.from(l));
8431
8432
  for (let c = 1; c < h.length; c++) a = this[Ot](h[c]);
8432
- } else a = this[Ot](_t.from(h));
8433
+ } else a = this[Ot](gt.from(h));
8433
8434
  return i && i(), a;
8434
8435
  }
8435
8436
  };
8436
- var Me = class extends ne {
8437
+ var Be = class extends ne {
8437
8438
  #t;
8438
8439
  #i;
8439
8440
  constructor(t, e) {
@@ -8444,7 +8445,7 @@ var Me = class extends ne {
8444
8445
  if (!this.handle) throw new Error("cannot switch params when binding is closed");
8445
8446
  if (!this.handle.params) throw new Error("not supported in this implementation");
8446
8447
  if (this.#t !== t || this.#i !== e) {
8447
- this.flush(M.Z_SYNC_FLUSH), vi(this.handle, "zlib binding closed");
8448
+ this.flush(M.Z_SYNC_FLUSH), Mi(this.handle, "zlib binding closed");
8448
8449
  let i = this.handle.flush;
8449
8450
  this.handle.flush = (r, n) => {
8450
8451
  typeof r == "function" && (n = r, r = this.flushFlag), this.flush(r), n?.();
@@ -8459,7 +8460,7 @@ var Me = class extends ne {
8459
8460
  }
8460
8461
  }
8461
8462
  };
8462
- var Be = class extends Me {
8463
+ var Pe = class extends Be {
8463
8464
  #t;
8464
8465
  constructor(t) {
8465
8466
  super(t, "Gzip"), this.#t = t && !!t.portable;
@@ -8468,87 +8469,87 @@ var Be = class extends Me {
8468
8469
  return this.#t ? (this.#t = false, t[9] = 255, super[Ot](t)) : super[Ot](t);
8469
8470
  }
8470
8471
  };
8471
- var Pe = class extends Me {
8472
+ var ze = class extends Be {
8472
8473
  constructor(t) {
8473
8474
  super(t, "Unzip");
8474
8475
  }
8475
8476
  };
8476
- var ze = class extends ne {
8477
+ var Ue = class extends ne {
8477
8478
  constructor(t, e) {
8478
8479
  t = t || {}, t.flush = t.flush || M.BROTLI_OPERATION_PROCESS, t.finishFlush = t.finishFlush || M.BROTLI_OPERATION_FINISH, t.fullFlushFlag = M.BROTLI_OPERATION_FLUSH, super(t, e);
8479
8480
  }
8480
8481
  };
8481
- var Ue = class extends ze {
8482
+ var He = class extends Ue {
8482
8483
  constructor(t) {
8483
8484
  super(t, "BrotliCompress");
8484
8485
  }
8485
8486
  };
8486
- var He = class extends ze {
8487
+ var We = class extends Ue {
8487
8488
  constructor(t) {
8488
8489
  super(t, "BrotliDecompress");
8489
8490
  }
8490
8491
  };
8491
- var We = class extends ne {
8492
+ var Ge = class extends ne {
8492
8493
  constructor(t, e) {
8493
8494
  t = t || {}, t.flush = t.flush || M.ZSTD_e_continue, t.finishFlush = t.finishFlush || M.ZSTD_e_end, t.fullFlushFlag = M.ZSTD_e_flush, super(t, e);
8494
8495
  }
8495
8496
  };
8496
- var Ge = class extends We {
8497
+ var Ze = class extends Ge {
8497
8498
  constructor(t) {
8498
8499
  super(t, "ZstdCompress");
8499
8500
  }
8500
8501
  };
8501
- var Ze = class extends We {
8502
+ var Ye = class extends Ge {
8502
8503
  constructor(t) {
8503
8504
  super(t, "ZstdDecompress");
8504
8505
  }
8505
8506
  };
8506
- var Bs = (s3, t) => {
8507
- if (Number.isSafeInteger(s3)) s3 < 0 ? jr(s3, t) : qr(s3, t);
8507
+ var Ms = (s3, t) => {
8508
+ if (Number.isSafeInteger(s3)) s3 < 0 ? qr(s3, t) : Xr(s3, t);
8508
8509
  else throw Error("cannot encode number outside of javascript safe integer range");
8509
8510
  return t;
8510
8511
  };
8511
- var qr = (s3, t) => {
8512
+ var Xr = (s3, t) => {
8512
8513
  t[0] = 128;
8513
8514
  for (var e = t.length; e > 1; e--) t[e - 1] = s3 & 255, s3 = Math.floor(s3 / 256);
8514
8515
  };
8515
- var jr = (s3, t) => {
8516
+ var qr = (s3, t) => {
8516
8517
  t[0] = 255;
8517
8518
  var e = false;
8518
8519
  s3 = s3 * -1;
8519
8520
  for (var i = t.length; i > 1; i--) {
8520
8521
  var r = s3 & 255;
8521
- s3 = Math.floor(s3 / 256), e ? t[i - 1] = zs(r) : r === 0 ? t[i - 1] = 0 : (e = true, t[i - 1] = Us(r));
8522
+ s3 = Math.floor(s3 / 256), e ? t[i - 1] = Ps(r) : r === 0 ? t[i - 1] = 0 : (e = true, t[i - 1] = zs(r));
8522
8523
  }
8523
8524
  };
8524
- var Ps = (s3) => {
8525
- let t = s3[0], e = t === 128 ? Jr(s3.subarray(1, s3.length)) : t === 255 ? Qr(s3) : null;
8525
+ var Bs = (s3) => {
8526
+ let t = s3[0], e = t === 128 ? Qr(s3.subarray(1, s3.length)) : t === 255 ? jr(s3) : null;
8526
8527
  if (e === null) throw Error("invalid base256 encoding");
8527
8528
  if (!Number.isSafeInteger(e)) throw Error("parsed number outside of javascript safe integer range");
8528
8529
  return e;
8529
8530
  };
8530
- var Qr = (s3) => {
8531
+ var jr = (s3) => {
8531
8532
  for (var t = s3.length, e = 0, i = false, r = t - 1; r > -1; r--) {
8532
8533
  var n = Number(s3[r]), o;
8533
- i ? o = zs(n) : n === 0 ? o = n : (i = true, o = Us(n)), o !== 0 && (e -= o * Math.pow(256, t - r - 1));
8534
+ i ? o = Ps(n) : n === 0 ? o = n : (i = true, o = zs(n)), o !== 0 && (e -= o * Math.pow(256, t - r - 1));
8534
8535
  }
8535
8536
  return e;
8536
8537
  };
8537
- var Jr = (s3) => {
8538
+ var Qr = (s3) => {
8538
8539
  for (var t = s3.length, e = 0, i = t - 1; i > -1; i--) {
8539
8540
  var r = Number(s3[i]);
8540
8541
  r !== 0 && (e += r * Math.pow(256, t - i - 1));
8541
8542
  }
8542
8543
  return e;
8543
8544
  };
8544
- var zs = (s3) => (255 ^ s3) & 255;
8545
- var Us = (s3) => (255 ^ s3) + 1 & 255;
8546
- var Mi = {};
8547
- Ar(Mi, { code: () => Ye, isCode: () => oe, isName: () => en, name: () => he });
8545
+ var Ps = (s3) => (255 ^ s3) & 255;
8546
+ var zs = (s3) => (255 ^ s3) + 1 & 255;
8547
+ var Bi = {};
8548
+ Ar(Bi, { code: () => Ke, isCode: () => oe, isName: () => tn, name: () => he });
8548
8549
  var oe = (s3) => he.has(s3);
8549
- var en = (s3) => Ye.has(s3);
8550
+ var tn = (s3) => Ke.has(s3);
8550
8551
  var he = /* @__PURE__ */ new Map([["0", "File"], ["", "OldFile"], ["1", "Link"], ["2", "SymbolicLink"], ["3", "CharacterDevice"], ["4", "BlockDevice"], ["5", "Directory"], ["6", "FIFO"], ["7", "ContiguousFile"], ["g", "GlobalExtendedHeader"], ["x", "ExtendedHeader"], ["A", "SolarisACL"], ["D", "GNUDumpDir"], ["I", "Inode"], ["K", "NextFileHasLongLinkpath"], ["L", "NextFileHasLongPath"], ["M", "ContinuationFile"], ["N", "OldGnuLongPath"], ["S", "SparseFile"], ["V", "TapeVolumeHeader"], ["X", "OldExtendedHeader"]]);
8551
- var Ye = new Map(Array.from(he).map((s3) => [s3[1], s3[0]]));
8552
+ var Ke = new Map(Array.from(he).map((s3) => [s3[1], s3[0]]));
8552
8553
  var F = class {
8553
8554
  cksumValid = false;
8554
8555
  needPax = false;
@@ -8576,14 +8577,14 @@ var F = class {
8576
8577
  }
8577
8578
  decode(t, e, i, r) {
8578
8579
  if (e || (e = 0), !t || !(t.length >= e + 512)) throw new Error("need 512 bytes for header");
8579
- this.path = i?.path ?? Tt(t, e, 100), this.mode = i?.mode ?? r?.mode ?? at(t, e + 100, 8), this.uid = i?.uid ?? r?.uid ?? at(t, e + 108, 8), this.gid = i?.gid ?? r?.gid ?? at(t, e + 116, 8), this.size = i?.size ?? r?.size ?? at(t, e + 124, 12), this.mtime = i?.mtime ?? r?.mtime ?? Bi(t, e + 136, 12), this.cksum = at(t, e + 148, 12), r && this.#i(r, true), i && this.#i(i);
8580
+ this.path = i?.path ?? Tt(t, e, 100), this.mode = i?.mode ?? r?.mode ?? at(t, e + 100, 8), this.uid = i?.uid ?? r?.uid ?? at(t, e + 108, 8), this.gid = i?.gid ?? r?.gid ?? at(t, e + 116, 8), this.size = i?.size ?? r?.size ?? at(t, e + 124, 12), this.mtime = i?.mtime ?? r?.mtime ?? Pi(t, e + 136, 12), this.cksum = at(t, e + 148, 12), r && this.#i(r, true), i && this.#i(i);
8580
8581
  let n = Tt(t, e + 156, 1);
8581
8582
  if (oe(n) && (this.#t = n || "0"), this.#t === "0" && this.path.slice(-1) === "/" && (this.#t = "5"), this.#t === "5" && (this.size = 0), this.linkpath = Tt(t, e + 157, 100), t.subarray(e + 257, e + 265).toString() === "ustar\x0000") if (this.uname = i?.uname ?? r?.uname ?? Tt(t, e + 265, 32), this.gname = i?.gname ?? r?.gname ?? Tt(t, e + 297, 32), this.devmaj = i?.devmaj ?? r?.devmaj ?? at(t, e + 329, 8) ?? 0, this.devmin = i?.devmin ?? r?.devmin ?? at(t, e + 337, 8) ?? 0, t[e + 475] !== 0) {
8582
8583
  let h = Tt(t, e + 345, 155);
8583
8584
  this.path = h + "/" + this.path;
8584
8585
  } else {
8585
8586
  let h = Tt(t, e + 345, 130);
8586
- h && (this.path = h + "/" + this.path), this.atime = i?.atime ?? r?.atime ?? Bi(t, e + 476, 12), this.ctime = i?.ctime ?? r?.ctime ?? Bi(t, e + 488, 12);
8587
+ h && (this.path = h + "/" + this.path), this.atime = i?.atime ?? r?.atime ?? Pi(t, e + 476, 12), this.ctime = i?.ctime ?? r?.ctime ?? Pi(t, e + 488, 12);
8587
8588
  }
8588
8589
  let o = 256;
8589
8590
  for (let h = e; h < e + 148; h++) o += t[h];
@@ -8595,8 +8596,8 @@ var F = class {
8595
8596
  }
8596
8597
  encode(t, e = 0) {
8597
8598
  if (t || (t = this.block = Buffer.alloc(512)), this.#t === "Unsupported" && (this.#t = "0"), !(t.length >= e + 512)) throw new Error("need 512 bytes for header");
8598
- let i = this.ctime || this.atime ? 130 : 155, r = sn(this.path || "", i), n = r[0], o = r[1];
8599
- this.needPax = !!r[2], this.needPax = xt(t, e, 100, n) || this.needPax, this.needPax = lt(t, e + 100, 8, this.mode) || this.needPax, this.needPax = lt(t, e + 108, 8, this.uid) || this.needPax, this.needPax = lt(t, e + 116, 8, this.gid) || this.needPax, this.needPax = lt(t, e + 124, 12, this.size) || this.needPax, this.needPax = Pi(t, e + 136, 12, this.mtime) || this.needPax, t[e + 156] = this.#t.charCodeAt(0), this.needPax = xt(t, e + 157, 100, this.linkpath) || this.needPax, t.write("ustar\x0000", e + 257, 8), this.needPax = xt(t, e + 265, 32, this.uname) || this.needPax, this.needPax = xt(t, e + 297, 32, this.gname) || this.needPax, this.needPax = lt(t, e + 329, 8, this.devmaj) || this.needPax, this.needPax = lt(t, e + 337, 8, this.devmin) || this.needPax, this.needPax = xt(t, e + 345, i, o) || this.needPax, t[e + 475] !== 0 ? this.needPax = xt(t, e + 345, 155, o) || this.needPax : (this.needPax = xt(t, e + 345, 130, o) || this.needPax, this.needPax = Pi(t, e + 476, 12, this.atime) || this.needPax, this.needPax = Pi(t, e + 488, 12, this.ctime) || this.needPax);
8599
+ let i = this.ctime || this.atime ? 130 : 155, r = en(this.path || "", i), n = r[0], o = r[1];
8600
+ this.needPax = !!r[2], this.needPax = xt(t, e, 100, n) || this.needPax, this.needPax = lt(t, e + 100, 8, this.mode) || this.needPax, this.needPax = lt(t, e + 108, 8, this.uid) || this.needPax, this.needPax = lt(t, e + 116, 8, this.gid) || this.needPax, this.needPax = lt(t, e + 124, 12, this.size) || this.needPax, this.needPax = zi(t, e + 136, 12, this.mtime) || this.needPax, t[e + 156] = Number(this.#t.codePointAt(0)), this.needPax = xt(t, e + 157, 100, this.linkpath) || this.needPax, t.write("ustar\x0000", e + 257, 8), this.needPax = xt(t, e + 265, 32, this.uname) || this.needPax, this.needPax = xt(t, e + 297, 32, this.gname) || this.needPax, this.needPax = lt(t, e + 329, 8, this.devmaj) || this.needPax, this.needPax = lt(t, e + 337, 8, this.devmin) || this.needPax, this.needPax = xt(t, e + 345, i, o) || this.needPax, t[e + 475] !== 0 ? this.needPax = xt(t, e + 345, 155, o) || this.needPax : (this.needPax = xt(t, e + 345, 130, o) || this.needPax, this.needPax = zi(t, e + 476, 12, this.atime) || this.needPax, this.needPax = zi(t, e + 488, 12, this.ctime) || this.needPax);
8600
8601
  let h = 256;
8601
8602
  for (let a = e; a < e + 148; a++) h += t[a];
8602
8603
  for (let a = e + 156; a < e + 512; a++) h += t[a];
@@ -8609,13 +8610,13 @@ var F = class {
8609
8610
  return this.#t;
8610
8611
  }
8611
8612
  set type(t) {
8612
- let e = String(Ye.get(t));
8613
+ let e = String(Ke.get(t));
8613
8614
  if (oe(e) || e === "Unsupported") this.#t = e;
8614
8615
  else if (oe(t)) this.#t = t;
8615
8616
  else throw new TypeError("invalid entry type: " + t);
8616
8617
  }
8617
8618
  };
8618
- var sn = (s3, t) => {
8619
+ var en = (s3, t) => {
8619
8620
  let i = s3, r = "", n, o = Zt.parse(s3).root || ".";
8620
8621
  if (Buffer.byteLength(i) < 100) n = [i, r, false];
8621
8622
  else {
@@ -8628,19 +8629,19 @@ var sn = (s3, t) => {
8628
8629
  return n;
8629
8630
  };
8630
8631
  var Tt = (s3, t, e) => s3.subarray(t, t + e).toString("utf8").replace(/\0.*/, "");
8631
- var Bi = (s3, t, e) => rn(at(s3, t, e));
8632
- var rn = (s3) => s3 === void 0 ? void 0 : new Date(s3 * 1e3);
8633
- var at = (s3, t, e) => Number(s3[t]) & 128 ? Ps(s3.subarray(t, t + e)) : on(s3, t, e);
8634
- var nn = (s3) => isNaN(s3) ? void 0 : s3;
8635
- var on = (s3, t, e) => nn(parseInt(s3.subarray(t, t + e).toString("utf8").replace(/\0.*$/, "").trim(), 8));
8636
- var hn = { 12: 8589934591, 8: 2097151 };
8637
- var lt = (s3, t, e, i) => i === void 0 ? false : i > hn[e] || i < 0 ? (Bs(i, s3.subarray(t, t + e)), true) : (an(s3, t, e, i), false);
8638
- var an = (s3, t, e, i) => s3.write(ln(i, e), t, e, "ascii");
8639
- var ln = (s3, t) => cn(Math.floor(s3).toString(8), t);
8640
- var cn = (s3, t) => (s3.length === t - 1 ? s3 : new Array(t - s3.length - 1).join("0") + s3 + " ") + "\0";
8641
- var Pi = (s3, t, e, i) => i === void 0 ? false : lt(s3, t, e, i.getTime() / 1e3);
8642
- var fn = new Array(156).join("\0");
8643
- var xt = (s3, t, e, i) => i === void 0 ? false : (s3.write(i + fn, t, e, "utf8"), i.length !== Buffer.byteLength(i) || i.length > e);
8632
+ var Pi = (s3, t, e) => sn(at(s3, t, e));
8633
+ var sn = (s3) => s3 === void 0 ? void 0 : new Date(s3 * 1e3);
8634
+ var at = (s3, t, e) => Number(s3[t]) & 128 ? Bs(s3.subarray(t, t + e)) : nn(s3, t, e);
8635
+ var rn = (s3) => isNaN(s3) ? void 0 : s3;
8636
+ var nn = (s3, t, e) => rn(parseInt(s3.subarray(t, t + e).toString("utf8").replace(/\0.*$/, "").trim(), 8));
8637
+ var on = { 12: 8589934591, 8: 2097151 };
8638
+ var lt = (s3, t, e, i) => i === void 0 ? false : i > on[e] || i < 0 ? (Ms(i, s3.subarray(t, t + e)), true) : (hn(s3, t, e, i), false);
8639
+ var hn = (s3, t, e, i) => s3.write(an(i, e), t, e, "ascii");
8640
+ var an = (s3, t) => ln(Math.floor(s3).toString(8), t);
8641
+ var ln = (s3, t) => (s3.length === t - 1 ? s3 : new Array(t - s3.length - 1).join("0") + s3 + " ") + "\0";
8642
+ var zi = (s3, t, e, i) => i === void 0 ? false : lt(s3, t, e, i.getTime() / 1e3);
8643
+ var cn = new Array(156).join("\0");
8644
+ var xt = (s3, t, e, i) => i === void 0 ? false : (s3.write(i + cn, t, e, "utf8"), i.length !== Buffer.byteLength(i) || i.length > e);
8644
8645
  var ct = class s {
8645
8646
  atime;
8646
8647
  mtime;
@@ -8667,7 +8668,7 @@ var ct = class s {
8667
8668
  if (t === "") return Buffer.allocUnsafe(0);
8668
8669
  let e = Buffer.byteLength(t), i = 512 * Math.ceil(1 + e / 512), r = Buffer.allocUnsafe(i);
8669
8670
  for (let n = 0; n < 512; n++) r[n] = 0;
8670
- new F({ path: ("PaxHeader/" + dn(this.path ?? "")).slice(0, 99), mode: this.mode || 420, uid: this.uid, gid: this.gid, size: e, mtime: this.mtime, type: this.global ? "GlobalExtendedHeader" : "ExtendedHeader", linkpath: "", uname: this.uname || "", gname: this.gname || "", devmaj: 0, devmin: 0, atime: this.atime, ctime: this.ctime }).encode(r), r.write(t, 512, e, "utf8");
8671
+ new F({ path: ("PaxHeader/" + fn(this.path ?? "")).slice(0, 99), mode: this.mode || 420, uid: this.uid, gid: this.gid, size: e, mtime: this.mtime, type: this.global ? "GlobalExtendedHeader" : "ExtendedHeader", linkpath: "", uname: this.uname || "", gname: this.gname || "", devmaj: 0, devmin: 0, atime: this.atime, ctime: this.ctime }).encode(r), r.write(t, 512, e, "utf8");
8671
8672
  for (let n = e + 512; n < r.length; n++) r[n] = 0;
8672
8673
  return r;
8673
8674
  }
@@ -8681,13 +8682,13 @@ var ct = class s {
8681
8682
  return n + o >= Math.pow(10, o) && (o += 1), o + n + r;
8682
8683
  }
8683
8684
  static parse(t, e, i = false) {
8684
- return new s(un(mn(t), e), i);
8685
+ return new s(dn(un(t), e), i);
8685
8686
  }
8686
8687
  };
8687
- var un = (s3, t) => t ? Object.assign({}, t, s3) : s3;
8688
- var mn = (s3) => s3.replace(/\n$/, "").split(`
8689
- `).reduce(pn, /* @__PURE__ */ Object.create(null));
8690
- var pn = (s3, t) => {
8688
+ var dn = (s3, t) => t ? Object.assign({}, t, s3) : s3;
8689
+ var un = (s3) => s3.replace(/\n$/, "").split(`
8690
+ `).reduce(mn, /* @__PURE__ */ Object.create(null));
8691
+ var mn = (s3, t) => {
8691
8692
  let e = parseInt(t, 10);
8692
8693
  if (e !== Buffer.byteLength(t) + 1) return s3;
8693
8694
  t = t.slice((e + " ").length);
@@ -8696,9 +8697,9 @@ var pn = (s3, t) => {
8696
8697
  let n = r.replace(/^SCHILY\.(dev|ino|nlink)/, "$1"), o = i.join("=");
8697
8698
  return s3[n] = /^([A-Z]+\.)?([mac]|birth|creation)time$/.test(n) ? new Date(Number(o) * 1e3) : /^[0-9]+$/.test(o) ? +o : o, s3;
8698
8699
  };
8699
- var En = process.env.TESTING_TAR_FAKE_PLATFORM || process.platform;
8700
- var f = En !== "win32" ? (s3) => s3 : (s3) => s3 && s3.replace(/\\/g, "/");
8701
- var Yt = class extends A {
8700
+ var pn = process.env.TESTING_TAR_FAKE_PLATFORM || process.platform;
8701
+ var f = pn !== "win32" ? (s3) => s3 : (s3) => s3 && s3.replaceAll(/\\/g, "/");
8702
+ var Yt = class extends D {
8702
8703
  extended;
8703
8704
  globalExtended;
8704
8705
  header;
@@ -8765,42 +8766,42 @@ var Yt = class extends A {
8765
8766
  var Lt = (s3, t, e, i = {}) => {
8766
8767
  s3.file && (i.file = s3.file), s3.cwd && (i.cwd = s3.cwd), i.code = e instanceof Error && e.code || t, i.tarCode = t, !s3.strict && i.recoverable !== false ? (e instanceof Error && (i = Object.assign(e, i), e = e.message), s3.emit("warn", t, e, i)) : e instanceof Error ? s3.emit("error", Object.assign(e, i)) : s3.emit("error", Object.assign(new Error(`${t}: ${e}`), i));
8767
8768
  };
8768
- var Sn = 1024 * 1024;
8769
- var Gi = Buffer.from([31, 139]);
8770
- var Zi = Buffer.from([40, 181, 47, 253]);
8771
- var yn = Math.max(Gi.length, Zi.length);
8769
+ var wn = 1024 * 1024;
8770
+ var Zi = Buffer.from([31, 139]);
8771
+ var Yi = Buffer.from([40, 181, 47, 253]);
8772
+ var Sn = Math.max(Zi.length, Yi.length);
8772
8773
  var B = /* @__PURE__ */ Symbol("state");
8773
8774
  var Nt = /* @__PURE__ */ Symbol("writeEntry");
8774
8775
  var et = /* @__PURE__ */ Symbol("readEntry");
8775
- var zi = /* @__PURE__ */ Symbol("nextEntry");
8776
- var Hs = /* @__PURE__ */ Symbol("processEntry");
8776
+ var Ui = /* @__PURE__ */ Symbol("nextEntry");
8777
+ var Us = /* @__PURE__ */ Symbol("processEntry");
8777
8778
  var V = /* @__PURE__ */ Symbol("extendedHeader");
8778
8779
  var ae = /* @__PURE__ */ Symbol("globalExtendedHeader");
8779
8780
  var ft = /* @__PURE__ */ Symbol("meta");
8780
- var Ws = /* @__PURE__ */ Symbol("emitMeta");
8781
+ var Hs = /* @__PURE__ */ Symbol("emitMeta");
8781
8782
  var p = /* @__PURE__ */ Symbol("buffer");
8782
8783
  var it = /* @__PURE__ */ Symbol("queue");
8783
8784
  var dt = /* @__PURE__ */ Symbol("ended");
8784
- var Ui = /* @__PURE__ */ Symbol("emittedEnd");
8785
- var Dt = /* @__PURE__ */ Symbol("emit");
8785
+ var Hi = /* @__PURE__ */ Symbol("emittedEnd");
8786
+ var At = /* @__PURE__ */ Symbol("emit");
8786
8787
  var y = /* @__PURE__ */ Symbol("unzip");
8787
- var Ke = /* @__PURE__ */ Symbol("consumeChunk");
8788
- var Ve = /* @__PURE__ */ Symbol("consumeChunkSub");
8789
- var Hi = /* @__PURE__ */ Symbol("consumeBody");
8790
- var Gs = /* @__PURE__ */ Symbol("consumeMeta");
8791
- var Zs = /* @__PURE__ */ Symbol("consumeHeader");
8788
+ var Ve = /* @__PURE__ */ Symbol("consumeChunk");
8789
+ var $e = /* @__PURE__ */ Symbol("consumeChunkSub");
8790
+ var Wi = /* @__PURE__ */ Symbol("consumeBody");
8791
+ var Ws = /* @__PURE__ */ Symbol("consumeMeta");
8792
+ var Gs = /* @__PURE__ */ Symbol("consumeHeader");
8792
8793
  var le = /* @__PURE__ */ Symbol("consuming");
8793
- var Wi = /* @__PURE__ */ Symbol("bufferConcat");
8794
- var $e = /* @__PURE__ */ Symbol("maybeEnd");
8794
+ var Gi = /* @__PURE__ */ Symbol("bufferConcat");
8795
+ var Xe = /* @__PURE__ */ Symbol("maybeEnd");
8795
8796
  var Kt = /* @__PURE__ */ Symbol("writing");
8796
8797
  var ut = /* @__PURE__ */ Symbol("aborted");
8797
- var Xe = /* @__PURE__ */ Symbol("onDone");
8798
- var At = /* @__PURE__ */ Symbol("sawValidEntry");
8799
- var qe = /* @__PURE__ */ Symbol("sawNullBlock");
8800
- var je = /* @__PURE__ */ Symbol("sawEOF");
8801
- var Ys = /* @__PURE__ */ Symbol("closeStream");
8802
- var Rn = () => true;
8803
- var st = class extends wn {
8798
+ var qe = /* @__PURE__ */ Symbol("onDone");
8799
+ var Dt = /* @__PURE__ */ Symbol("sawValidEntry");
8800
+ var je = /* @__PURE__ */ Symbol("sawNullBlock");
8801
+ var Qe = /* @__PURE__ */ Symbol("sawEOF");
8802
+ var Zs = /* @__PURE__ */ Symbol("closeStream");
8803
+ var yn = () => true;
8804
+ var st = class extends En {
8804
8805
  file;
8805
8806
  strict;
8806
8807
  maxMetaEntrySize;
@@ -8820,36 +8821,36 @@ var st = class extends wn {
8820
8821
  [dt] = false;
8821
8822
  [y];
8822
8823
  [ut] = false;
8823
- [At];
8824
- [qe] = false;
8824
+ [Dt];
8825
8825
  [je] = false;
8826
+ [Qe] = false;
8826
8827
  [Kt] = false;
8827
8828
  [le] = false;
8828
- [Ui] = false;
8829
+ [Hi] = false;
8829
8830
  constructor(t = {}) {
8830
- super(), this.file = t.file || "", this.on(Xe, () => {
8831
- (this[B] === "begin" || this[At] === false) && this.warn("TAR_BAD_ARCHIVE", "Unrecognized archive format");
8832
- }), t.ondone ? this.on(Xe, t.ondone) : this.on(Xe, () => {
8831
+ super(), this.file = t.file || "", this.on(qe, () => {
8832
+ (this[B] === "begin" || this[Dt] === false) && this.warn("TAR_BAD_ARCHIVE", "Unrecognized archive format");
8833
+ }), t.ondone ? this.on(qe, t.ondone) : this.on(qe, () => {
8833
8834
  this.emit("prefinish"), this.emit("finish"), this.emit("end");
8834
- }), this.strict = !!t.strict, this.maxMetaEntrySize = t.maxMetaEntrySize || Sn, this.filter = typeof t.filter == "function" ? t.filter : Rn;
8835
+ }), this.strict = !!t.strict, this.maxMetaEntrySize = t.maxMetaEntrySize || wn, this.filter = typeof t.filter == "function" ? t.filter : yn;
8835
8836
  let e = t.file && (t.file.endsWith(".tar.br") || t.file.endsWith(".tbr"));
8836
8837
  this.brotli = !(t.gzip || t.zstd) && t.brotli !== void 0 ? t.brotli : e ? void 0 : false;
8837
8838
  let i = t.file && (t.file.endsWith(".tar.zst") || t.file.endsWith(".tzst"));
8838
- this.zstd = !(t.gzip || t.brotli) && t.zstd !== void 0 ? t.zstd : i ? true : void 0, this.on("end", () => this[Ys]()), typeof t.onwarn == "function" && this.on("warn", t.onwarn), typeof t.onReadEntry == "function" && this.on("entry", t.onReadEntry);
8839
+ this.zstd = !(t.gzip || t.brotli) && t.zstd !== void 0 ? t.zstd : i ? true : void 0, this.on("end", () => this[Zs]()), typeof t.onwarn == "function" && this.on("warn", t.onwarn), typeof t.onReadEntry == "function" && this.on("entry", t.onReadEntry);
8839
8840
  }
8840
8841
  warn(t, e, i = {}) {
8841
8842
  Lt(this, t, e, i);
8842
8843
  }
8843
- [Zs](t, e) {
8844
- this[At] === void 0 && (this[At] = false);
8844
+ [Gs](t, e) {
8845
+ this[Dt] === void 0 && (this[Dt] = false);
8845
8846
  let i;
8846
8847
  try {
8847
8848
  i = new F(t, e, this[V], this[ae]);
8848
8849
  } catch (r) {
8849
8850
  return this.warn("TAR_ENTRY_INVALID", r);
8850
8851
  }
8851
- if (i.nullBlock) this[qe] ? (this[je] = true, this[B] === "begin" && (this[B] = "header"), this[Dt]("eof")) : (this[qe] = true, this[Dt]("nullBlock"));
8852
- else if (this[qe] = false, !i.cksumValid) this.warn("TAR_ENTRY_INVALID", "checksum failure", { header: i });
8852
+ if (i.nullBlock) this[je] ? (this[Qe] = true, this[B] === "begin" && (this[B] = "header"), this[At]("eof")) : (this[je] = true, this[At]("nullBlock"));
8853
+ else if (this[je] = false, !i.cksumValid) this.warn("TAR_ENTRY_INVALID", "checksum failure", { header: i });
8853
8854
  else if (!i.path) this.warn("TAR_ENTRY_INVALID", "path is required", { header: i });
8854
8855
  else {
8855
8856
  let r = i.type;
@@ -8857,52 +8858,52 @@ var st = class extends wn {
8857
8858
  else if (!/^(Symbolic)?Link$/.test(r) && !/^(Global)?ExtendedHeader$/.test(r) && i.linkpath) this.warn("TAR_ENTRY_INVALID", "linkpath forbidden", { header: i });
8858
8859
  else {
8859
8860
  let n = this[Nt] = new Yt(i, this[V], this[ae]);
8860
- if (!this[At]) if (n.remain) {
8861
+ if (!this[Dt]) if (n.remain) {
8861
8862
  let o = () => {
8862
- n.invalid || (this[At] = true);
8863
+ n.invalid || (this[Dt] = true);
8863
8864
  };
8864
8865
  n.on("end", o);
8865
- } else this[At] = true;
8866
- n.meta ? n.size > this.maxMetaEntrySize ? (n.ignore = true, this[Dt]("ignoredEntry", n), this[B] = "ignore", n.resume()) : n.size > 0 && (this[ft] = "", n.on("data", (o) => this[ft] += o), this[B] = "meta") : (this[V] = void 0, n.ignore = n.ignore || !this.filter(n.path, n), n.ignore ? (this[Dt]("ignoredEntry", n), this[B] = n.remain ? "ignore" : "header", n.resume()) : (n.remain ? this[B] = "body" : (this[B] = "header", n.end()), this[et] ? this[it].push(n) : (this[it].push(n), this[zi]())));
8866
+ } else this[Dt] = true;
8867
+ n.meta ? n.size > this.maxMetaEntrySize ? (n.ignore = true, this[At]("ignoredEntry", n), this[B] = "ignore", n.resume()) : n.size > 0 && (this[ft] = "", n.on("data", (o) => this[ft] += o), this[B] = "meta") : (this[V] = void 0, n.ignore = n.ignore || !this.filter(n.path, n), n.ignore ? (this[At]("ignoredEntry", n), this[B] = n.remain ? "ignore" : "header", n.resume()) : (n.remain ? this[B] = "body" : (this[B] = "header", n.end()), this[et] ? this[it].push(n) : (this[it].push(n), this[Ui]())));
8867
8868
  }
8868
8869
  }
8869
8870
  }
8870
- [Ys]() {
8871
+ [Zs]() {
8871
8872
  queueMicrotask(() => this.emit("close"));
8872
8873
  }
8873
- [Hs](t) {
8874
+ [Us](t) {
8874
8875
  let e = true;
8875
8876
  if (!t) this[et] = void 0, e = false;
8876
8877
  else if (Array.isArray(t)) {
8877
8878
  let [i, ...r] = t;
8878
8879
  this.emit(i, ...r);
8879
- } else this[et] = t, this.emit("entry", t), t.emittedEnd || (t.on("end", () => this[zi]()), e = false);
8880
+ } else this[et] = t, this.emit("entry", t), t.emittedEnd || (t.on("end", () => this[Ui]()), e = false);
8880
8881
  return e;
8881
8882
  }
8882
- [zi]() {
8883
+ [Ui]() {
8883
8884
  do
8884
8885
  ;
8885
- while (this[Hs](this[it].shift()));
8886
- if (!this[it].length) {
8886
+ while (this[Us](this[it].shift()));
8887
+ if (this[it].length === 0) {
8887
8888
  let t = this[et];
8888
8889
  !t || t.flowing || t.size === t.remain ? this[Kt] || this.emit("drain") : t.once("drain", () => this.emit("drain"));
8889
8890
  }
8890
8891
  }
8891
- [Hi](t, e) {
8892
+ [Wi](t, e) {
8892
8893
  let i = this[Nt];
8893
8894
  if (!i) throw new Error("attempt to consume body without entry??");
8894
8895
  let r = i.blockRemain ?? 0, n = r >= t.length && e === 0 ? t : t.subarray(e, e + r);
8895
8896
  return i.write(n), i.blockRemain || (this[B] = "header", this[Nt] = void 0, i.end()), n.length;
8896
8897
  }
8897
- [Gs](t, e) {
8898
- let i = this[Nt], r = this[Hi](t, e);
8899
- return !this[Nt] && i && this[Ws](i), r;
8898
+ [Ws](t, e) {
8899
+ let i = this[Nt], r = this[Wi](t, e);
8900
+ return !this[Nt] && i && this[Hs](i), r;
8900
8901
  }
8901
- [Dt](t, e, i) {
8902
- !this[it].length && !this[et] ? this.emit(t, e, i) : this[it].push([t, e, i]);
8902
+ [At](t, e, i) {
8903
+ this[it].length === 0 && !this[et] ? this.emit(t, e, i) : this[it].push([t, e, i]);
8903
8904
  }
8904
- [Ws](t) {
8905
- switch (this[Dt]("meta", this[ft]), t.type) {
8905
+ [Hs](t) {
8906
+ switch (this[At]("meta", this[ft]), t.type) {
8906
8907
  case "ExtendedHeader":
8907
8908
  case "OldExtendedHeader":
8908
8909
  this[V] = ct.parse(this[ft], this[V], false);
@@ -8931,12 +8932,12 @@ var st = class extends wn {
8931
8932
  write(t, e, i) {
8932
8933
  if (typeof e == "function" && (i = e, e = void 0), typeof t == "string" && (t = Buffer.from(t, typeof e == "string" ? e : "utf8")), this[ut]) return i?.(), false;
8933
8934
  if ((this[y] === void 0 || this.brotli === void 0 && this[y] === false) && t) {
8934
- if (this[p] && (t = Buffer.concat([this[p], t]), this[p] = void 0), t.length < yn) return this[p] = t, i?.(), true;
8935
- for (let a = 0; this[y] === void 0 && a < Gi.length; a++) t[a] !== Gi[a] && (this[y] = false);
8935
+ if (this[p] && (t = Buffer.concat([this[p], t]), this[p] = void 0), t.length < Sn) return this[p] = t, i?.(), true;
8936
+ for (let a = 0; this[y] === void 0 && a < Zi.length; a++) t[a] !== Zi[a] && (this[y] = false);
8936
8937
  let o = false;
8937
8938
  if (this[y] === false && this.zstd !== false) {
8938
8939
  o = true;
8939
- for (let a = 0; a < Zi.length; a++) if (t[a] !== Zi[a]) {
8940
+ for (let a = 0; a < Yi.length; a++) if (t[a] !== Yi[a]) {
8940
8941
  o = false;
8941
8942
  break;
8942
8943
  }
@@ -8951,69 +8952,69 @@ var st = class extends wn {
8951
8952
  }
8952
8953
  if (this[y] === void 0 || this[y] === false && (this.brotli || o)) {
8953
8954
  let a = this[dt];
8954
- this[dt] = false, this[y] = this[y] === void 0 ? new Pe({}) : o ? new Ze({}) : new He({}), this[y].on("data", (c) => this[Ke](c)), this[y].on("error", (c) => this.abort(c)), this[y].on("end", () => {
8955
- this[dt] = true, this[Ke]();
8955
+ this[dt] = false, this[y] = this[y] === void 0 ? new ze({}) : o ? new Ye({}) : new We({}), this[y].on("data", (c) => this[Ve](c)), this[y].on("error", (c) => this.abort(c)), this[y].on("end", () => {
8956
+ this[dt] = true, this[Ve]();
8956
8957
  }), this[Kt] = true;
8957
8958
  let l = !!this[y][a ? "end" : "write"](t);
8958
8959
  return this[Kt] = false, i?.(), l;
8959
8960
  }
8960
8961
  }
8961
- this[Kt] = true, this[y] ? this[y].write(t) : this[Ke](t), this[Kt] = false;
8962
- let n = this[it].length ? false : this[et] ? this[et].flowing : true;
8963
- return !n && !this[it].length && this[et]?.once("drain", () => this.emit("drain")), i?.(), n;
8962
+ this[Kt] = true, this[y] ? this[y].write(t) : this[Ve](t), this[Kt] = false;
8963
+ let n = this[it].length > 0 ? false : this[et] ? this[et].flowing : true;
8964
+ return !n && this[it].length === 0 && this[et]?.once("drain", () => this.emit("drain")), i?.(), n;
8964
8965
  }
8965
- [Wi](t) {
8966
+ [Gi](t) {
8966
8967
  t && !this[ut] && (this[p] = this[p] ? Buffer.concat([this[p], t]) : t);
8967
8968
  }
8968
- [$e]() {
8969
- if (this[dt] && !this[Ui] && !this[ut] && !this[le]) {
8970
- this[Ui] = true;
8969
+ [Xe]() {
8970
+ if (this[dt] && !this[Hi] && !this[ut] && !this[le]) {
8971
+ this[Hi] = true;
8971
8972
  let t = this[Nt];
8972
8973
  if (t && t.blockRemain) {
8973
8974
  let e = this[p] ? this[p].length : 0;
8974
8975
  this.warn("TAR_BAD_ARCHIVE", `Truncated input (needed ${t.blockRemain} more bytes, only ${e} available)`, { entry: t }), this[p] && t.write(this[p]), t.end();
8975
8976
  }
8976
- this[Dt](Xe);
8977
+ this[At](qe);
8977
8978
  }
8978
8979
  }
8979
- [Ke](t) {
8980
- if (this[le] && t) this[Wi](t);
8981
- else if (!t && !this[p]) this[$e]();
8980
+ [Ve](t) {
8981
+ if (this[le] && t) this[Gi](t);
8982
+ else if (!t && !this[p]) this[Xe]();
8982
8983
  else if (t) {
8983
8984
  if (this[le] = true, this[p]) {
8984
- this[Wi](t);
8985
+ this[Gi](t);
8985
8986
  let e = this[p];
8986
- this[p] = void 0, this[Ve](e);
8987
- } else this[Ve](t);
8988
- for (; this[p] && this[p]?.length >= 512 && !this[ut] && !this[je]; ) {
8987
+ this[p] = void 0, this[$e](e);
8988
+ } else this[$e](t);
8989
+ for (; this[p] && this[p]?.length >= 512 && !this[ut] && !this[Qe]; ) {
8989
8990
  let e = this[p];
8990
- this[p] = void 0, this[Ve](e);
8991
+ this[p] = void 0, this[$e](e);
8991
8992
  }
8992
8993
  this[le] = false;
8993
8994
  }
8994
- (!this[p] || this[dt]) && this[$e]();
8995
+ (!this[p] || this[dt]) && this[Xe]();
8995
8996
  }
8996
- [Ve](t) {
8997
+ [$e](t) {
8997
8998
  let e = 0, i = t.length;
8998
- for (; e + 512 <= i && !this[ut] && !this[je]; ) switch (this[B]) {
8999
+ for (; e + 512 <= i && !this[ut] && !this[Qe]; ) switch (this[B]) {
8999
9000
  case "begin":
9000
9001
  case "header":
9001
- this[Zs](t, e), e += 512;
9002
+ this[Gs](t, e), e += 512;
9002
9003
  break;
9003
9004
  case "ignore":
9004
9005
  case "body":
9005
- e += this[Hi](t, e);
9006
+ e += this[Wi](t, e);
9006
9007
  break;
9007
9008
  case "meta":
9008
- e += this[Gs](t, e);
9009
+ e += this[Ws](t, e);
9009
9010
  break;
9010
9011
  default:
9011
9012
  throw new Error("invalid state: " + this[B]);
9012
9013
  }
9013
- e < i && (this[p] ? this[p] = Buffer.concat([t.subarray(e), this[p]]) : this[p] = t.subarray(e));
9014
+ e < i && (this[p] = this[p] ? Buffer.concat([t.subarray(e), this[p]]) : t.subarray(e));
9014
9015
  }
9015
9016
  end(t, e, i) {
9016
- 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[ut] || (this[y] ? (t && this[y].write(t), this[y].end()) : (this[dt] = true, (this.brotli === void 0 || this.zstd === void 0) && (t = t || Buffer.alloc(0)), t && this.write(t), this[$e]())), this;
9017
+ 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[ut] || (this[y] ? (t && this[y].write(t), this[y].end()) : (this[dt] = true, (this.brotli === void 0 || this.zstd === void 0) && (t = t || Buffer.alloc(0)), t && this.write(t), this[Xe]())), this;
9017
9018
  }
9018
9019
  };
9019
9020
  var mt = (s3) => {
@@ -9027,19 +9028,19 @@ var _n = (s3) => {
9027
9028
  t(e), e.resume();
9028
9029
  } : (e) => e.resume();
9029
9030
  };
9030
- var Yi = (s3, t) => {
9031
+ var Ki = (s3, t) => {
9031
9032
  let e = new Map(t.map((n) => [mt(n), true])), i = s3.filter, r = (n, o = "") => {
9032
- let h = o || gn(n).root || ".", a;
9033
+ let h = o || bn(n).root || ".", a;
9033
9034
  if (n === h) a = false;
9034
9035
  else {
9035
9036
  let l = e.get(n);
9036
- l !== void 0 ? a = l : a = r(bn(n), h);
9037
+ a = l !== void 0 ? l : r(Rn(n), h);
9037
9038
  }
9038
9039
  return e.set(n, a), a;
9039
9040
  };
9040
9041
  s3.filter = i ? (n, o) => i(n, o) && r(mt(n)) : (n) => r(mt(n));
9041
9042
  };
9042
- var On = (s3) => {
9043
+ var gn = (s3) => {
9043
9044
  let t = new st(s3), e = s3.file, i;
9044
9045
  try {
9045
9046
  i = Vt.openSync(e, "r");
@@ -9063,58 +9064,58 @@ var On = (s3) => {
9063
9064
  }
9064
9065
  }
9065
9066
  };
9066
- var Tn = (s3, t) => {
9067
+ var On = (s3, t) => {
9067
9068
  let e = new st(s3), i = s3.maxReadSize || 16 * 1024 * 1024, r = s3.file;
9068
9069
  return new Promise((o, h) => {
9069
9070
  e.on("error", h), e.on("end", o), Vt.stat(r, (a, l) => {
9070
9071
  if (a) h(a);
9071
9072
  else {
9072
- let c = new gt(r, { readSize: i, size: l.size });
9073
+ let c = new _t(r, { readSize: i, size: l.size });
9073
9074
  c.on("error", h), c.pipe(e);
9074
9075
  }
9075
9076
  });
9076
9077
  });
9077
9078
  };
9078
- var It = K(On, Tn, (s3) => new st(s3), (s3) => new st(s3), (s3, t) => {
9079
- t?.length && Yi(s3, t), s3.noResume || _n(s3);
9079
+ var It = K(gn, On, (s3) => new st(s3), (s3) => new st(s3), (s3, t) => {
9080
+ t?.length && Ki(s3, t), s3.noResume || _n(s3);
9080
9081
  });
9081
- var Ki = (s3, t, e) => (s3 &= 4095, e && (s3 = (s3 | 384) & -19), t && (s3 & 256 && (s3 |= 64), s3 & 32 && (s3 |= 8), s3 & 4 && (s3 |= 1)), s3);
9082
- var { isAbsolute: Ln, parse: Ks } = xn;
9082
+ var Vi = (s3, t, e) => (s3 &= 4095, e && (s3 = (s3 | 384) & -19), t && (s3 & 256 && (s3 |= 64), s3 & 32 && (s3 |= 8), s3 & 4 && (s3 |= 1)), s3);
9083
+ var { isAbsolute: xn, parse: Ys } = Tn;
9083
9084
  var ce = (s3) => {
9084
- let t = "", e = Ks(s3);
9085
- for (; Ln(s3) || e.root; ) {
9085
+ let t = "", e = Ys(s3);
9086
+ for (; xn(s3) || e.root; ) {
9086
9087
  let i = s3.charAt(0) === "/" && s3.slice(0, 4) !== "//?/" ? "/" : e.root;
9087
- s3 = s3.slice(i.length), t += i, e = Ks(s3);
9088
+ s3 = s3.slice(i.length), t += i, e = Ys(s3);
9088
9089
  }
9089
9090
  return [t, s3];
9090
9091
  };
9091
- var Qe = ["|", "<", ">", "?", ":"];
9092
- var Vi = Qe.map((s3) => String.fromCharCode(61440 + s3.charCodeAt(0)));
9093
- var Nn = new Map(Qe.map((s3, t) => [s3, Vi[t]]));
9094
- var Dn = new Map(Vi.map((s3, t) => [s3, Qe[t]]));
9095
- var $i = (s3) => Qe.reduce((t, e) => t.split(e).join(Nn.get(e)), s3);
9096
- var Vs = (s3) => Vi.reduce((t, e) => t.split(e).join(Dn.get(e)), s3);
9097
- var tr = (s3, t) => t ? (s3 = f(s3).replace(/^\.(\/|$)/, ""), mt(t) + "/" + s3) : f(s3);
9092
+ var Je = ["|", "<", ">", "?", ":"];
9093
+ var $i = Je.map((s3) => String.fromCodePoint(61440 + Number(s3.codePointAt(0))));
9094
+ var Ln = new Map(Je.map((s3, t) => [s3, $i[t]]));
9095
+ var Nn = new Map($i.map((s3, t) => [s3, Je[t]]));
9096
+ var Xi = (s3) => Je.reduce((t, e) => t.split(e).join(Ln.get(e)), s3);
9097
+ var Ks = (s3) => $i.reduce((t, e) => t.split(e).join(Nn.get(e)), s3);
9098
+ var Js = (s3, t) => t ? (s3 = f(s3).replace(/^\.(\/|$)/, ""), mt(t) + "/" + s3) : f(s3);
9098
9099
  var An = 16 * 1024 * 1024;
9099
- var qs = /* @__PURE__ */ Symbol("process");
9100
- var js = /* @__PURE__ */ Symbol("file");
9101
- var Qs = /* @__PURE__ */ Symbol("directory");
9102
- var qi = /* @__PURE__ */ Symbol("symlink");
9103
- var Js = /* @__PURE__ */ Symbol("hardlink");
9100
+ var Xs = /* @__PURE__ */ Symbol("process");
9101
+ var qs = /* @__PURE__ */ Symbol("file");
9102
+ var js = /* @__PURE__ */ Symbol("directory");
9103
+ var ji = /* @__PURE__ */ Symbol("symlink");
9104
+ var Qs = /* @__PURE__ */ Symbol("hardlink");
9104
9105
  var fe = /* @__PURE__ */ Symbol("header");
9105
- var Je = /* @__PURE__ */ Symbol("read");
9106
- var ji = /* @__PURE__ */ Symbol("lstat");
9107
- var ti = /* @__PURE__ */ Symbol("onlstat");
9108
- var Qi = /* @__PURE__ */ Symbol("onread");
9109
- var Ji = /* @__PURE__ */ Symbol("onreadlink");
9110
- var ts = /* @__PURE__ */ Symbol("openfile");
9111
- var es = /* @__PURE__ */ Symbol("onopenfile");
9106
+ var ti = /* @__PURE__ */ Symbol("read");
9107
+ var Qi = /* @__PURE__ */ Symbol("lstat");
9108
+ var ei = /* @__PURE__ */ Symbol("onlstat");
9109
+ var Ji = /* @__PURE__ */ Symbol("onread");
9110
+ var ts = /* @__PURE__ */ Symbol("onreadlink");
9111
+ var es = /* @__PURE__ */ Symbol("openfile");
9112
+ var is = /* @__PURE__ */ Symbol("onopenfile");
9112
9113
  var pt = /* @__PURE__ */ Symbol("close");
9113
- var ei = /* @__PURE__ */ Symbol("mode");
9114
- var is = /* @__PURE__ */ Symbol("awaitDrain");
9115
- var Xi = /* @__PURE__ */ Symbol("ondrain");
9114
+ var ii = /* @__PURE__ */ Symbol("mode");
9115
+ var ss = /* @__PURE__ */ Symbol("awaitDrain");
9116
+ var qi = /* @__PURE__ */ Symbol("ondrain");
9116
9117
  var X = /* @__PURE__ */ Symbol("prefix");
9117
- var de = class extends A {
9118
+ var de = class extends D {
9118
9119
  path;
9119
9120
  portable;
9120
9121
  myuid = process.getuid && process.getuid() || 0;
@@ -9153,9 +9154,9 @@ var de = class extends A {
9153
9154
  let [o, h] = ce(this.path);
9154
9155
  o && typeof h == "string" && (this.path = h, r = o);
9155
9156
  }
9156
- this.win32 = !!i.win32 || process.platform === "win32", this.win32 && (this.path = Vs(this.path.replace(/\\/g, "/")), t = t.replace(/\\/g, "/")), this.absolute = f(i.absolute || Xs.resolve(this.cwd, t)), this.path === "" && (this.path = "./"), r && this.warn("TAR_ENTRY_INFO", `stripping ${r} from absolute path`, { entry: this, path: r + this.path });
9157
+ this.win32 = !!i.win32 || process.platform === "win32", this.win32 && (this.path = Ks(this.path.replaceAll(/\\/g, "/")), t = t.replaceAll(/\\/g, "/")), this.absolute = f(i.absolute || $s.resolve(this.cwd, t)), this.path === "" && (this.path = "./"), r && this.warn("TAR_ENTRY_INFO", `stripping ${r} from absolute path`, { entry: this, path: r + this.path });
9157
9158
  let n = this.statCache.get(this.absolute);
9158
- n ? this[ti](n) : this[ji]();
9159
+ n ? this[ei](n) : this[Qi]();
9159
9160
  }
9160
9161
  warn(t, e, i = {}) {
9161
9162
  return Lt(this, t, e, i);
@@ -9163,93 +9164,93 @@ var de = class extends A {
9163
9164
  emit(t, ...e) {
9164
9165
  return t === "error" && (this.#t = true), super.emit(t, ...e);
9165
9166
  }
9166
- [ji]() {
9167
+ [Qi]() {
9167
9168
  $2.lstat(this.absolute, (t, e) => {
9168
9169
  if (t) return this.emit("error", t);
9169
- this[ti](e);
9170
+ this[ei](e);
9170
9171
  });
9171
9172
  }
9172
- [ti](t) {
9173
- this.statCache.set(this.absolute, t), this.stat = t, t.isFile() || (t.size = 0), this.type = In(t), this.emit("stat", t), this[qs]();
9173
+ [ei](t) {
9174
+ this.statCache.set(this.absolute, t), this.stat = t, t.isFile() || (t.size = 0), this.type = Dn(t), this.emit("stat", t), this[Xs]();
9174
9175
  }
9175
- [qs]() {
9176
+ [Xs]() {
9176
9177
  switch (this.type) {
9177
9178
  case "File":
9178
- return this[js]();
9179
+ return this[qs]();
9179
9180
  case "Directory":
9180
- return this[Qs]();
9181
+ return this[js]();
9181
9182
  case "SymbolicLink":
9182
- return this[qi]();
9183
+ return this[ji]();
9183
9184
  default:
9184
9185
  return this.end();
9185
9186
  }
9186
9187
  }
9187
- [ei](t) {
9188
- return Ki(t, this.type === "Directory", this.portable);
9188
+ [ii](t) {
9189
+ return Vi(t, this.type === "Directory", this.portable);
9189
9190
  }
9190
9191
  [X](t) {
9191
- return tr(t, this.prefix);
9192
+ return Js(t, this.prefix);
9192
9193
  }
9193
9194
  [fe]() {
9194
9195
  if (!this.stat) throw new Error("cannot write header before stat");
9195
- this.type === "Directory" && this.portable && (this.noMtime = true), this.onWriteEntry?.(this), this.header = new F({ path: this[X](this.path), linkpath: this.type === "Link" && this.linkpath !== void 0 ? this[X](this.linkpath) : this.linkpath, mode: this[ei](this.stat.mode), uid: this.portable ? void 0 : this.stat.uid, gid: this.portable ? void 0 : this.stat.gid, size: this.stat.size, mtime: this.noMtime ? void 0 : this.mtime || this.stat.mtime, type: this.type === "Unsupported" ? void 0 : this.type, uname: this.portable ? void 0 : this.stat.uid === this.myuid ? this.myuser : "", atime: this.portable ? void 0 : this.stat.atime, ctime: this.portable ? void 0 : this.stat.ctime }), this.header.encode() && !this.noPax && super.write(new ct({ atime: this.portable ? void 0 : this.header.atime, ctime: this.portable ? void 0 : this.header.ctime, gid: this.portable ? void 0 : this.header.gid, mtime: this.noMtime ? void 0 : this.mtime || this.header.mtime, path: this[X](this.path), linkpath: this.type === "Link" && this.linkpath !== void 0 ? this[X](this.linkpath) : this.linkpath, size: this.header.size, uid: this.portable ? void 0 : this.header.uid, uname: this.portable ? void 0 : this.header.uname, dev: this.portable ? void 0 : this.stat.dev, ino: this.portable ? void 0 : this.stat.ino, nlink: this.portable ? void 0 : this.stat.nlink }).encode());
9196
+ this.type === "Directory" && this.portable && (this.noMtime = true), this.onWriteEntry?.(this), this.header = new F({ path: this[X](this.path), linkpath: this.type === "Link" && this.linkpath !== void 0 ? this[X](this.linkpath) : this.linkpath, mode: this[ii](this.stat.mode), uid: this.portable ? void 0 : this.stat.uid, gid: this.portable ? void 0 : this.stat.gid, size: this.stat.size, mtime: this.noMtime ? void 0 : this.mtime || this.stat.mtime, type: this.type === "Unsupported" ? void 0 : this.type, uname: this.portable ? void 0 : this.stat.uid === this.myuid ? this.myuser : "", atime: this.portable ? void 0 : this.stat.atime, ctime: this.portable ? void 0 : this.stat.ctime }), this.header.encode() && !this.noPax && super.write(new ct({ atime: this.portable ? void 0 : this.header.atime, ctime: this.portable ? void 0 : this.header.ctime, gid: this.portable ? void 0 : this.header.gid, mtime: this.noMtime ? void 0 : this.mtime || this.header.mtime, path: this[X](this.path), linkpath: this.type === "Link" && this.linkpath !== void 0 ? this[X](this.linkpath) : this.linkpath, size: this.header.size, uid: this.portable ? void 0 : this.header.uid, uname: this.portable ? void 0 : this.header.uname, dev: this.portable ? void 0 : this.stat.dev, ino: this.portable ? void 0 : this.stat.ino, nlink: this.portable ? void 0 : this.stat.nlink }).encode());
9196
9197
  let t = this.header?.block;
9197
9198
  if (!t) throw new Error("failed to encode header");
9198
9199
  super.write(t);
9199
9200
  }
9200
- [Qs]() {
9201
+ [js]() {
9201
9202
  if (!this.stat) throw new Error("cannot create directory entry without stat");
9202
9203
  this.path.slice(-1) !== "/" && (this.path += "/"), this.stat.size = 0, this[fe](), this.end();
9203
9204
  }
9204
- [qi]() {
9205
+ [ji]() {
9205
9206
  $2.readlink(this.absolute, (t, e) => {
9206
9207
  if (t) return this.emit("error", t);
9207
- this[Ji](e);
9208
+ this[ts](e);
9208
9209
  });
9209
9210
  }
9210
- [Ji](t) {
9211
+ [ts](t) {
9211
9212
  this.linkpath = f(t), this[fe](), this.end();
9212
9213
  }
9213
- [Js](t) {
9214
+ [Qs](t) {
9214
9215
  if (!this.stat) throw new Error("cannot create link entry without stat");
9215
- this.type = "Link", this.linkpath = f(Xs.relative(this.cwd, t)), this.stat.size = 0, this[fe](), this.end();
9216
+ this.type = "Link", this.linkpath = f($s.relative(this.cwd, t)), this.stat.size = 0, this[fe](), this.end();
9216
9217
  }
9217
- [js]() {
9218
+ [qs]() {
9218
9219
  if (!this.stat) throw new Error("cannot create file entry without stat");
9219
9220
  if (this.stat.nlink > 1) {
9220
9221
  let t = `${this.stat.dev}:${this.stat.ino}`, e = this.linkCache.get(t);
9221
- if (e?.indexOf(this.cwd) === 0) return this[Js](e);
9222
+ if (e?.indexOf(this.cwd) === 0) return this[Qs](e);
9222
9223
  this.linkCache.set(t, this.absolute);
9223
9224
  }
9224
9225
  if (this[fe](), this.stat.size === 0) return this.end();
9225
- this[ts]();
9226
+ this[es]();
9226
9227
  }
9227
- [ts]() {
9228
+ [es]() {
9228
9229
  $2.open(this.absolute, "r", (t, e) => {
9229
9230
  if (t) return this.emit("error", t);
9230
- this[es](e);
9231
+ this[is](e);
9231
9232
  });
9232
9233
  }
9233
- [es](t) {
9234
+ [is](t) {
9234
9235
  if (this.fd = t, this.#t) return this[pt]();
9235
9236
  if (!this.stat) throw new Error("should stat before calling onopenfile");
9236
9237
  this.blockLen = 512 * Math.ceil(this.stat.size / 512), this.blockRemain = this.blockLen;
9237
9238
  let e = Math.min(this.blockLen, this.maxReadSize);
9238
- this.buf = Buffer.allocUnsafe(e), this.offset = 0, this.pos = 0, this.remain = this.stat.size, this.length = this.buf.length, this[Je]();
9239
+ this.buf = Buffer.allocUnsafe(e), this.offset = 0, this.pos = 0, this.remain = this.stat.size, this.length = this.buf.length, this[ti]();
9239
9240
  }
9240
- [Je]() {
9241
+ [ti]() {
9241
9242
  let { fd: t, buf: e, offset: i, length: r, pos: n } = this;
9242
9243
  if (t === void 0 || e === void 0) throw new Error("cannot read file without first opening");
9243
9244
  $2.read(t, e, i, r, n, (o, h) => {
9244
9245
  if (o) return this[pt](() => this.emit("error", o));
9245
- this[Qi](h);
9246
+ this[Ji](h);
9246
9247
  });
9247
9248
  }
9248
9249
  [pt](t = () => {
9249
9250
  }) {
9250
9251
  this.fd !== void 0 && $2.close(this.fd, t);
9251
9252
  }
9252
- [Qi](t) {
9253
+ [Ji](t) {
9253
9254
  if (t <= 0 && this.remain > 0) {
9254
9255
  let r = Object.assign(new Error("encountered unexpected EOF"), { path: this.absolute, syscall: "read", code: "EOF" });
9255
9256
  return this[pt](() => this.emit("error", r));
@@ -9261,9 +9262,9 @@ var de = class extends A {
9261
9262
  if (!this.buf) throw new Error("should have created buffer prior to reading");
9262
9263
  if (t === this.remain) for (let r = t; r < this.length && t < this.blockRemain; r++) this.buf[r + this.offset] = 0, t++, this.remain++;
9263
9264
  let e = this.offset === 0 && t === this.buf.length ? this.buf : this.buf.subarray(this.offset, this.offset + t);
9264
- this.write(e) ? this[Xi]() : this[is](() => this[Xi]());
9265
+ this.write(e) ? this[qi]() : this[ss](() => this[qi]());
9265
9266
  }
9266
- [is](t) {
9267
+ [ss](t) {
9267
9268
  this.once("drain", t);
9268
9269
  }
9269
9270
  write(t, e, i) {
@@ -9273,30 +9274,30 @@ var de = class extends A {
9273
9274
  }
9274
9275
  return this.remain -= t.length, this.blockRemain -= t.length, this.pos += t.length, this.offset += t.length, super.write(t, null, i);
9275
9276
  }
9276
- [Xi]() {
9277
+ [qi]() {
9277
9278
  if (!this.remain) return this.blockRemain && super.write(Buffer.alloc(this.blockRemain)), this[pt]((t) => t ? this.emit("error", t) : this.end());
9278
9279
  if (!this.buf) throw new Error("buffer lost somehow in ONDRAIN");
9279
- this.offset >= this.length && (this.buf = Buffer.allocUnsafe(Math.min(this.blockRemain, this.buf.length)), this.offset = 0), this.length = this.buf.length - this.offset, this[Je]();
9280
+ this.offset >= this.length && (this.buf = Buffer.allocUnsafe(Math.min(this.blockRemain, this.buf.length)), this.offset = 0), this.length = this.buf.length - this.offset, this[ti]();
9280
9281
  }
9281
9282
  };
9282
- var ii = class extends de {
9283
+ var si = class extends de {
9283
9284
  sync = true;
9284
- [ji]() {
9285
- this[ti]($2.lstatSync(this.absolute));
9285
+ [Qi]() {
9286
+ this[ei]($2.lstatSync(this.absolute));
9286
9287
  }
9287
- [qi]() {
9288
- this[Ji]($2.readlinkSync(this.absolute));
9288
+ [ji]() {
9289
+ this[ts]($2.readlinkSync(this.absolute));
9289
9290
  }
9290
- [ts]() {
9291
- this[es]($2.openSync(this.absolute, "r"));
9291
+ [es]() {
9292
+ this[is]($2.openSync(this.absolute, "r"));
9292
9293
  }
9293
- [Je]() {
9294
+ [ti]() {
9294
9295
  let t = true;
9295
9296
  try {
9296
9297
  let { fd: e, buf: i, offset: r, length: n, pos: o } = this;
9297
9298
  if (e === void 0 || i === void 0) throw new Error("fd and buf must be set in READ method");
9298
9299
  let h = $2.readSync(e, i, r, n, o);
9299
- this[Qi](h), t = false;
9300
+ this[Ji](h), t = false;
9300
9301
  } finally {
9301
9302
  if (t) try {
9302
9303
  this[pt](() => {
@@ -9305,7 +9306,7 @@ var ii = class extends de {
9305
9306
  }
9306
9307
  }
9307
9308
  }
9308
- [is](t) {
9309
+ [ss](t) {
9309
9310
  t();
9310
9311
  }
9311
9312
  [pt](t = () => {
@@ -9313,7 +9314,7 @@ var ii = class extends de {
9313
9314
  this.fd !== void 0 && $2.closeSync(this.fd), t();
9314
9315
  }
9315
9316
  };
9316
- var si = class extends A {
9317
+ var ri = class extends D {
9317
9318
  blockLen = 0;
9318
9319
  blockRemain = 0;
9319
9320
  buf = 0;
@@ -9349,7 +9350,7 @@ var si = class extends A {
9349
9350
  super(), this.preservePaths = !!i.preservePaths, this.portable = !!i.portable, this.strict = !!i.strict, this.noPax = !!i.noPax, this.noMtime = !!i.noMtime, this.onWriteEntry = i.onWriteEntry, this.readEntry = t;
9350
9351
  let { type: r } = t;
9351
9352
  if (r === "Unsupported") throw new Error("writing entry that should be ignored");
9352
- this.type = r, this.type === "Directory" && this.portable && (this.noMtime = true), this.prefix = i.prefix, this.path = f(t.path), this.mode = t.mode !== void 0 ? this[ei](t.mode) : void 0, this.uid = this.portable ? void 0 : t.uid, this.gid = this.portable ? void 0 : t.gid, this.uname = this.portable ? void 0 : t.uname, this.gname = this.portable ? void 0 : t.gname, this.size = t.size, this.mtime = this.noMtime ? void 0 : i.mtime || t.mtime, this.atime = this.portable ? void 0 : t.atime, this.ctime = this.portable ? void 0 : t.ctime, this.linkpath = t.linkpath !== void 0 ? f(t.linkpath) : void 0, typeof i.onwarn == "function" && this.on("warn", i.onwarn);
9353
+ this.type = r, this.type === "Directory" && this.portable && (this.noMtime = true), this.prefix = i.prefix, this.path = f(t.path), this.mode = t.mode !== void 0 ? this[ii](t.mode) : void 0, this.uid = this.portable ? void 0 : t.uid, this.gid = this.portable ? void 0 : t.gid, this.uname = this.portable ? void 0 : t.uname, this.gname = this.portable ? void 0 : t.gname, this.size = t.size, this.mtime = this.noMtime ? void 0 : i.mtime || t.mtime, this.atime = this.portable ? void 0 : t.atime, this.ctime = this.portable ? void 0 : t.ctime, this.linkpath = t.linkpath !== void 0 ? f(t.linkpath) : void 0, typeof i.onwarn == "function" && this.on("warn", i.onwarn);
9353
9354
  let n = false;
9354
9355
  if (!this.preservePaths) {
9355
9356
  let [h, a] = ce(this.path);
@@ -9361,10 +9362,10 @@ var si = class extends A {
9361
9362
  super.write(o), t.pipe(this);
9362
9363
  }
9363
9364
  [X](t) {
9364
- return tr(t, this.prefix);
9365
+ return Js(t, this.prefix);
9365
9366
  }
9366
- [ei](t) {
9367
- return Ki(t, this.type === "Directory", this.portable);
9367
+ [ii](t) {
9368
+ return Vi(t, this.type === "Directory", this.portable);
9368
9369
  }
9369
9370
  write(t, e, i) {
9370
9371
  typeof e == "function" && (i = e, e = void 0), typeof t == "string" && (t = Buffer.from(t, typeof e == "string" ? e : "utf8"));
@@ -9376,8 +9377,8 @@ var si = class extends A {
9376
9377
  return this.blockRemain && super.write(Buffer.alloc(this.blockRemain)), 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 ?? "utf8")), i && this.once("finish", i), t ? super.end(t, i) : super.end(i), this;
9377
9378
  }
9378
9379
  };
9379
- var In = (s3) => s3.isFile() ? "File" : s3.isDirectory() ? "Directory" : s3.isSymbolicLink() ? "SymbolicLink" : "Unsupported";
9380
- var ri = class s2 {
9380
+ var Dn = (s3) => s3.isFile() ? "File" : s3.isDirectory() ? "Directory" : s3.isSymbolicLink() ? "SymbolicLink" : "Unsupported";
9381
+ var ni = class s2 {
9381
9382
  tail;
9382
9383
  head;
9383
9384
  length = 0;
@@ -9408,11 +9409,11 @@ var ri = class s2 {
9408
9409
  t.list = this, t.prev = e, e && (e.next = t), this.tail = t, this.head || (this.head = t), this.length++;
9409
9410
  }
9410
9411
  push(...t) {
9411
- for (let e = 0, i = t.length; e < i; e++) Fn(this, t[e]);
9412
+ for (let e = 0, i = t.length; e < i; e++) Cn(this, t[e]);
9412
9413
  return this.length;
9413
9414
  }
9414
9415
  unshift(...t) {
9415
- for (var e = 0, i = t.length; e < i; e++) kn(this, t[e]);
9416
+ for (var e = 0, i = t.length; e < i; e++) Fn(this, t[e]);
9416
9417
  return this.length;
9417
9418
  }
9418
9419
  pop() {
@@ -9508,7 +9509,7 @@ var ri = class s2 {
9508
9509
  let n = [];
9509
9510
  for (let o = 0; r && o < e; o++) n.push(r.value), r = this.removeNode(r);
9510
9511
  r ? r !== this.tail && (r = r.prev) : r = this.tail;
9511
- for (let o of i) r = Cn(this, r, o);
9512
+ for (let o of i) r = In(this, r, o);
9512
9513
  return n;
9513
9514
  }
9514
9515
  reverse() {
@@ -9520,14 +9521,14 @@ var ri = class s2 {
9520
9521
  return this.head = e, this.tail = t, this;
9521
9522
  }
9522
9523
  };
9523
- function Cn(s3, t, e) {
9524
+ function In(s3, t, e) {
9524
9525
  let i = t, r = t ? t.next : s3.head, n = new ue(e, i, r, s3);
9525
9526
  return n.next === void 0 && (s3.tail = n), n.prev === void 0 && (s3.head = n), s3.length++, n;
9526
9527
  }
9527
- function Fn(s3, t) {
9528
+ function Cn(s3, t) {
9528
9529
  s3.tail = new ue(t, s3.tail, void 0, s3), s3.head || (s3.head = s3.tail), s3.length++;
9529
9530
  }
9530
- function kn(s3, t) {
9531
+ function Fn(s3, t) {
9531
9532
  s3.head = new ue(t, void 0, s3.head, s3), s3.tail || (s3.tail = s3.head), s3.length++;
9532
9533
  }
9533
9534
  var ue = class {
@@ -9539,7 +9540,7 @@ var ue = class {
9539
9540
  this.list = r, this.value = t, e ? (e.next = this, this.prev = e) : this.prev = void 0, i ? (i.prev = this, this.next = i) : this.next = void 0;
9540
9541
  }
9541
9542
  };
9542
- var fi = class {
9543
+ var di = class {
9543
9544
  path;
9544
9545
  absolute;
9545
9546
  entry;
@@ -9552,28 +9553,28 @@ var fi = class {
9552
9553
  this.path = t || "./", this.absolute = e;
9553
9554
  }
9554
9555
  };
9555
- var er = Buffer.alloc(1024);
9556
- var ni = /* @__PURE__ */ Symbol("onStat");
9556
+ var tr = Buffer.alloc(1024);
9557
+ var oi = /* @__PURE__ */ Symbol("onStat");
9557
9558
  var me = /* @__PURE__ */ Symbol("ended");
9558
9559
  var W = /* @__PURE__ */ Symbol("queue");
9559
9560
  var Ct = /* @__PURE__ */ Symbol("current");
9560
9561
  var Ft = /* @__PURE__ */ Symbol("process");
9561
9562
  var pe = /* @__PURE__ */ Symbol("processing");
9562
- var ss = /* @__PURE__ */ Symbol("processJob");
9563
+ var rs = /* @__PURE__ */ Symbol("processJob");
9563
9564
  var G = /* @__PURE__ */ Symbol("jobs");
9564
- var rs = /* @__PURE__ */ Symbol("jobDone");
9565
- var oi = /* @__PURE__ */ Symbol("addFSEntry");
9566
- var ir = /* @__PURE__ */ Symbol("addTarEntry");
9567
- var hs = /* @__PURE__ */ Symbol("stat");
9568
- var as = /* @__PURE__ */ Symbol("readdir");
9569
- var hi = /* @__PURE__ */ Symbol("onreaddir");
9570
- var ai = /* @__PURE__ */ Symbol("pipe");
9571
- var sr = /* @__PURE__ */ Symbol("entry");
9572
- var ns = /* @__PURE__ */ Symbol("entryOpt");
9573
- var li = /* @__PURE__ */ Symbol("writeEntryClass");
9574
- var nr = /* @__PURE__ */ Symbol("write");
9575
- var os = /* @__PURE__ */ Symbol("ondrain");
9576
- var Et = class extends A {
9565
+ var ns = /* @__PURE__ */ Symbol("jobDone");
9566
+ var hi = /* @__PURE__ */ Symbol("addFSEntry");
9567
+ var er = /* @__PURE__ */ Symbol("addTarEntry");
9568
+ var as = /* @__PURE__ */ Symbol("stat");
9569
+ var ls = /* @__PURE__ */ Symbol("readdir");
9570
+ var ai = /* @__PURE__ */ Symbol("onreaddir");
9571
+ var li = /* @__PURE__ */ Symbol("pipe");
9572
+ var ir = /* @__PURE__ */ Symbol("entry");
9573
+ var os = /* @__PURE__ */ Symbol("entryOpt");
9574
+ var ci = /* @__PURE__ */ Symbol("writeEntryClass");
9575
+ var rr = /* @__PURE__ */ Symbol("write");
9576
+ var hs = /* @__PURE__ */ Symbol("ondrain");
9577
+ var Et = class extends D {
9577
9578
  sync = false;
9578
9579
  opt;
9579
9580
  cwd;
@@ -9594,22 +9595,22 @@ var Et = class extends A {
9594
9595
  mtime;
9595
9596
  filter;
9596
9597
  jobs;
9597
- [li];
9598
+ [ci];
9598
9599
  onWriteEntry;
9599
9600
  [W];
9600
9601
  [G] = 0;
9601
9602
  [pe] = false;
9602
9603
  [me] = false;
9603
9604
  constructor(t = {}) {
9604
- if (super(), this.opt = t, this.file = t.file || "", this.cwd = t.cwd || process.cwd(), this.maxReadSize = t.maxReadSize, this.preservePaths = !!t.preservePaths, this.strict = !!t.strict, this.noPax = !!t.noPax, this.prefix = f(t.prefix || ""), this.linkCache = t.linkCache || /* @__PURE__ */ new Map(), this.statCache = t.statCache || /* @__PURE__ */ new Map(), this.readdirCache = t.readdirCache || /* @__PURE__ */ new Map(), this.onWriteEntry = t.onWriteEntry, this[li] = de, typeof t.onwarn == "function" && this.on("warn", t.onwarn), this.portable = !!t.portable, t.gzip || t.brotli || t.zstd) {
9605
+ if (super(), this.opt = t, this.file = t.file || "", this.cwd = t.cwd || process.cwd(), this.maxReadSize = t.maxReadSize, this.preservePaths = !!t.preservePaths, this.strict = !!t.strict, this.noPax = !!t.noPax, this.prefix = f(t.prefix || ""), this.linkCache = t.linkCache || /* @__PURE__ */ new Map(), this.statCache = t.statCache || /* @__PURE__ */ new Map(), this.readdirCache = t.readdirCache || /* @__PURE__ */ new Map(), this.onWriteEntry = t.onWriteEntry, this[ci] = de, typeof t.onwarn == "function" && this.on("warn", t.onwarn), this.portable = !!t.portable, t.gzip || t.brotli || t.zstd) {
9605
9606
  if ((t.gzip ? 1 : 0) + (t.brotli ? 1 : 0) + (t.zstd ? 1 : 0) > 1) throw new TypeError("gzip, brotli, zstd are mutually exclusive");
9606
- if (t.gzip && (typeof t.gzip != "object" && (t.gzip = {}), this.portable && (t.gzip.portable = true), this.zip = new Be(t.gzip)), t.brotli && (typeof t.brotli != "object" && (t.brotli = {}), this.zip = new Ue(t.brotli)), t.zstd && (typeof t.zstd != "object" && (t.zstd = {}), this.zip = new Ge(t.zstd)), !this.zip) throw new Error("impossible");
9607
+ if (t.gzip && (typeof t.gzip != "object" && (t.gzip = {}), this.portable && (t.gzip.portable = true), this.zip = new Pe(t.gzip)), t.brotli && (typeof t.brotli != "object" && (t.brotli = {}), this.zip = new He(t.brotli)), t.zstd && (typeof t.zstd != "object" && (t.zstd = {}), this.zip = new Ze(t.zstd)), !this.zip) throw new Error("impossible");
9607
9608
  let e = this.zip;
9608
- e.on("data", (i) => super.write(i)), e.on("end", () => super.end()), e.on("drain", () => this[os]()), this.on("resume", () => e.resume());
9609
- } else this.on("drain", this[os]);
9610
- this.noDirRecurse = !!t.noDirRecurse, this.follow = !!t.follow, this.noMtime = !!t.noMtime, t.mtime && (this.mtime = t.mtime), this.filter = typeof t.filter == "function" ? t.filter : () => true, this[W] = new ri(), this[G] = 0, this.jobs = Number(t.jobs) || 4, this[pe] = false, this[me] = false;
9609
+ e.on("data", (i) => super.write(i)), e.on("end", () => super.end()), e.on("drain", () => this[hs]()), this.on("resume", () => e.resume());
9610
+ } else this.on("drain", this[hs]);
9611
+ this.noDirRecurse = !!t.noDirRecurse, this.follow = !!t.follow, this.noMtime = !!t.noMtime, t.mtime && (this.mtime = t.mtime), this.filter = typeof t.filter == "function" ? t.filter : () => true, this[W] = new ni(), this[G] = 0, this.jobs = Number(t.jobs) || 4, this[pe] = false, this[me] = false;
9611
9612
  }
9612
- [nr](t) {
9613
+ [rr](t) {
9613
9614
  return super.write(t);
9614
9615
  }
9615
9616
  add(t) {
@@ -9620,97 +9621,97 @@ var Et = class extends A {
9620
9621
  }
9621
9622
  write(t) {
9622
9623
  if (this[me]) throw new Error("write after end");
9623
- return t instanceof Yt ? this[ir](t) : this[oi](t), this.flowing;
9624
+ return t instanceof Yt ? this[er](t) : this[hi](t), this.flowing;
9624
9625
  }
9625
- [ir](t) {
9626
- let e = f(rr.resolve(this.cwd, t.path));
9626
+ [er](t) {
9627
+ let e = f(sr.resolve(this.cwd, t.path));
9627
9628
  if (!this.filter(t.path, t)) t.resume();
9628
9629
  else {
9629
- let i = new fi(t.path, e);
9630
- i.entry = new si(t, this[ns](i)), i.entry.on("end", () => this[rs](i)), this[G] += 1, this[W].push(i);
9630
+ let i = new di(t.path, e);
9631
+ i.entry = new ri(t, this[os](i)), i.entry.on("end", () => this[ns](i)), this[G] += 1, this[W].push(i);
9631
9632
  }
9632
9633
  this[Ft]();
9633
9634
  }
9634
- [oi](t) {
9635
- let e = f(rr.resolve(this.cwd, t));
9636
- this[W].push(new fi(t, e)), this[Ft]();
9635
+ [hi](t) {
9636
+ let e = f(sr.resolve(this.cwd, t));
9637
+ this[W].push(new di(t, e)), this[Ft]();
9637
9638
  }
9638
- [hs](t) {
9639
+ [as](t) {
9639
9640
  t.pending = true, this[G] += 1;
9640
9641
  let e = this.follow ? "stat" : "lstat";
9641
- ci[e](t.absolute, (i, r) => {
9642
- t.pending = false, this[G] -= 1, i ? this.emit("error", i) : this[ni](t, r);
9642
+ fi[e](t.absolute, (i, r) => {
9643
+ t.pending = false, this[G] -= 1, i ? this.emit("error", i) : this[oi](t, r);
9643
9644
  });
9644
9645
  }
9645
- [ni](t, e) {
9646
- this.statCache.set(t.absolute, e), t.stat = e, this.filter(t.path, e) ? e.isFile() && e.nlink > 1 && t === this[Ct] && !this.linkCache.get(`${e.dev}:${e.ino}`) && !this.sync && this[ss](t) : t.ignore = true, this[Ft]();
9646
+ [oi](t, e) {
9647
+ this.statCache.set(t.absolute, e), t.stat = e, this.filter(t.path, e) ? e.isFile() && e.nlink > 1 && t === this[Ct] && !this.linkCache.get(`${e.dev}:${e.ino}`) && !this.sync && this[rs](t) : t.ignore = true, this[Ft]();
9647
9648
  }
9648
- [as](t) {
9649
- t.pending = true, this[G] += 1, ci.readdir(t.absolute, (e, i) => {
9649
+ [ls](t) {
9650
+ t.pending = true, this[G] += 1, fi.readdir(t.absolute, (e, i) => {
9650
9651
  if (t.pending = false, this[G] -= 1, e) return this.emit("error", e);
9651
- this[hi](t, i);
9652
+ this[ai](t, i);
9652
9653
  });
9653
9654
  }
9654
- [hi](t, e) {
9655
+ [ai](t, e) {
9655
9656
  this.readdirCache.set(t.absolute, e), t.readdir = e, this[Ft]();
9656
9657
  }
9657
9658
  [Ft]() {
9658
9659
  if (!this[pe]) {
9659
9660
  this[pe] = true;
9660
- for (let t = this[W].head; t && this[G] < this.jobs; t = t.next) if (this[ss](t.value), t.value.ignore) {
9661
+ for (let t = this[W].head; t && this[G] < this.jobs; t = t.next) if (this[rs](t.value), t.value.ignore) {
9661
9662
  let e = t.next;
9662
9663
  this[W].removeNode(t), t.next = e;
9663
9664
  }
9664
- this[pe] = false, this[me] && !this[W].length && this[G] === 0 && (this.zip ? this.zip.end(er) : (super.write(er), super.end()));
9665
+ this[pe] = false, this[me] && this[W].length === 0 && this[G] === 0 && (this.zip ? this.zip.end(tr) : (super.write(tr), super.end()));
9665
9666
  }
9666
9667
  }
9667
9668
  get [Ct]() {
9668
9669
  return this[W] && this[W].head && this[W].head.value;
9669
9670
  }
9670
- [rs](t) {
9671
+ [ns](t) {
9671
9672
  this[W].shift(), this[G] -= 1, this[Ft]();
9672
9673
  }
9673
- [ss](t) {
9674
+ [rs](t) {
9674
9675
  if (!t.pending) {
9675
9676
  if (t.entry) {
9676
- t === this[Ct] && !t.piped && this[ai](t);
9677
+ t === this[Ct] && !t.piped && this[li](t);
9677
9678
  return;
9678
9679
  }
9679
9680
  if (!t.stat) {
9680
9681
  let e = this.statCache.get(t.absolute);
9681
- e ? this[ni](t, e) : this[hs](t);
9682
+ e ? this[oi](t, e) : this[as](t);
9682
9683
  }
9683
9684
  if (t.stat && !t.ignore) {
9684
9685
  if (!this.noDirRecurse && t.stat.isDirectory() && !t.readdir) {
9685
9686
  let e = this.readdirCache.get(t.absolute);
9686
- if (e ? this[hi](t, e) : this[as](t), !t.readdir) return;
9687
+ if (e ? this[ai](t, e) : this[ls](t), !t.readdir) return;
9687
9688
  }
9688
- if (t.entry = this[sr](t), !t.entry) {
9689
+ if (t.entry = this[ir](t), !t.entry) {
9689
9690
  t.ignore = true;
9690
9691
  return;
9691
9692
  }
9692
- t === this[Ct] && !t.piped && this[ai](t);
9693
+ t === this[Ct] && !t.piped && this[li](t);
9693
9694
  }
9694
9695
  }
9695
9696
  }
9696
- [ns](t) {
9697
+ [os](t) {
9697
9698
  return { onwarn: (e, i, r) => this.warn(e, i, r), noPax: this.noPax, cwd: this.cwd, absolute: t.absolute, preservePaths: this.preservePaths, maxReadSize: this.maxReadSize, strict: this.strict, portable: this.portable, linkCache: this.linkCache, statCache: this.statCache, noMtime: this.noMtime, mtime: this.mtime, prefix: this.prefix, onWriteEntry: this.onWriteEntry };
9698
9699
  }
9699
- [sr](t) {
9700
+ [ir](t) {
9700
9701
  this[G] += 1;
9701
9702
  try {
9702
- return new this[li](t.path, this[ns](t)).on("end", () => this[rs](t)).on("error", (i) => this.emit("error", i));
9703
+ return new this[ci](t.path, this[os](t)).on("end", () => this[ns](t)).on("error", (i) => this.emit("error", i));
9703
9704
  } catch (e) {
9704
9705
  this.emit("error", e);
9705
9706
  }
9706
9707
  }
9707
- [os]() {
9708
+ [hs]() {
9708
9709
  this[Ct] && this[Ct].entry && this[Ct].entry.resume();
9709
9710
  }
9710
- [ai](t) {
9711
+ [li](t) {
9711
9712
  t.piped = true, t.readdir && t.readdir.forEach((r) => {
9712
9713
  let n = t.path, o = n === "./" ? "" : n.replace(/\/*$/, "/");
9713
- this[oi](o + r);
9714
+ this[hi](o + r);
9714
9715
  });
9715
9716
  let e = t.entry, i = this.zip;
9716
9717
  if (!e) throw new Error("cannot pipe without source");
@@ -9730,131 +9731,128 @@ var Et = class extends A {
9730
9731
  var kt = class extends Et {
9731
9732
  sync = true;
9732
9733
  constructor(t) {
9733
- super(t), this[li] = ii;
9734
+ super(t), this[ci] = si;
9734
9735
  }
9735
9736
  pause() {
9736
9737
  }
9737
9738
  resume() {
9738
9739
  }
9739
- [hs](t) {
9740
+ [as](t) {
9740
9741
  let e = this.follow ? "statSync" : "lstatSync";
9741
- this[ni](t, ci[e](t.absolute));
9742
+ this[oi](t, fi[e](t.absolute));
9742
9743
  }
9743
- [as](t) {
9744
- this[hi](t, ci.readdirSync(t.absolute));
9744
+ [ls](t) {
9745
+ this[ai](t, fi.readdirSync(t.absolute));
9745
9746
  }
9746
- [ai](t) {
9747
+ [li](t) {
9747
9748
  let e = t.entry, i = this.zip;
9748
9749
  if (t.readdir && t.readdir.forEach((r) => {
9749
9750
  let n = t.path, o = n === "./" ? "" : n.replace(/\/*$/, "/");
9750
- this[oi](o + r);
9751
+ this[hi](o + r);
9751
9752
  }), !e) throw new Error("Cannot pipe without source");
9752
9753
  i ? e.on("data", (r) => {
9753
9754
  i.write(r);
9754
9755
  }) : e.on("data", (r) => {
9755
- super[nr](r);
9756
+ super[rr](r);
9756
9757
  });
9757
9758
  }
9758
9759
  };
9759
- var vn = (s3, t) => {
9760
+ var kn = (s3, t) => {
9760
9761
  let e = new kt(s3), i = new Wt(s3.file, { mode: s3.mode || 438 });
9761
- e.pipe(i), hr(e, t);
9762
+ e.pipe(i), or(e, t);
9762
9763
  };
9763
- var Mn = (s3, t) => {
9764
+ var vn = (s3, t) => {
9764
9765
  let e = new Et(s3), i = new tt2(s3.file, { mode: s3.mode || 438 });
9765
9766
  e.pipe(i);
9766
9767
  let r = new Promise((n, o) => {
9767
9768
  i.on("error", o), i.on("close", n), e.on("error", o);
9768
9769
  });
9769
- return ar(e, t), r;
9770
+ return hr(e, t).catch((n) => e.emit("error", n)), r;
9770
9771
  };
9771
- var hr = (s3, t) => {
9772
+ var or = (s3, t) => {
9772
9773
  t.forEach((e) => {
9773
- e.charAt(0) === "@" ? It({ file: or.resolve(s3.cwd, e.slice(1)), sync: true, noResume: true, onReadEntry: (i) => s3.add(i) }) : s3.add(e);
9774
+ e.charAt(0) === "@" ? It({ file: nr.resolve(s3.cwd, e.slice(1)), sync: true, noResume: true, onReadEntry: (i) => s3.add(i) }) : s3.add(e);
9774
9775
  }), s3.end();
9775
9776
  };
9776
- var ar = async (s3, t) => {
9777
- for (let e = 0; e < t.length; e++) {
9778
- let i = String(t[e]);
9779
- i.charAt(0) === "@" ? await It({ file: or.resolve(String(s3.cwd), i.slice(1)), noResume: true, onReadEntry: (r) => {
9780
- s3.add(r);
9781
- } }) : s3.add(i);
9782
- }
9777
+ var hr = async (s3, t) => {
9778
+ for (let e of t) e.charAt(0) === "@" ? await It({ file: nr.resolve(String(s3.cwd), e.slice(1)), noResume: true, onReadEntry: (i) => {
9779
+ s3.add(i);
9780
+ } }) : s3.add(e);
9783
9781
  s3.end();
9784
9782
  };
9785
- var Bn = (s3, t) => {
9783
+ var Mn = (s3, t) => {
9786
9784
  let e = new kt(s3);
9787
- return hr(e, t), e;
9785
+ return or(e, t), e;
9788
9786
  };
9789
- var Pn = (s3, t) => {
9787
+ var Bn = (s3, t) => {
9790
9788
  let e = new Et(s3);
9791
- return ar(e, t), e;
9789
+ return hr(e, t).catch((i) => e.emit("error", i)), e;
9792
9790
  };
9793
- var zn = K(vn, Mn, Bn, Pn, (s3, t) => {
9791
+ var Pn = K(kn, vn, Mn, Bn, (s3, t) => {
9794
9792
  if (!t?.length) throw new TypeError("no paths specified to add to archive");
9795
9793
  });
9796
- var Un = process.env.__FAKE_PLATFORM__ || process.platform;
9797
- var Hn = Un === "win32";
9798
- var { O_CREAT: Wn, O_TRUNC: Gn, O_WRONLY: Zn } = lr.constants;
9799
- var cr = Number(process.env.__FAKE_FS_O_FILENAME__) || lr.constants.UV_FS_O_FILEMAP || 0;
9800
- var Yn = Hn && !!cr;
9801
- var Kn = 512 * 1024;
9802
- var Vn = cr | Gn | Wn | Zn;
9803
- var ls = Yn ? (s3) => s3 < Kn ? Vn : "w" : () => "w";
9804
- var cs = (s3, t, e) => {
9794
+ var zn = process.env.__FAKE_PLATFORM__ || process.platform;
9795
+ var Un = zn === "win32";
9796
+ var { O_CREAT: Hn, O_TRUNC: Wn, O_WRONLY: Gn } = ar.constants;
9797
+ var lr = Number(process.env.__FAKE_FS_O_FILENAME__) || ar.constants.UV_FS_O_FILEMAP || 0;
9798
+ var Zn = Un && !!lr;
9799
+ var Yn = 512 * 1024;
9800
+ var Kn = lr | Wn | Hn | Gn;
9801
+ var cs = Zn ? (s3) => s3 < Yn ? Kn : "w" : () => "w";
9802
+ var fs2 = (s3, t, e) => {
9805
9803
  try {
9806
- return ui.lchownSync(s3, t, e);
9804
+ return mi.lchownSync(s3, t, e);
9807
9805
  } catch (i) {
9808
9806
  if (i?.code !== "ENOENT") throw i;
9809
9807
  }
9810
9808
  };
9811
- var di = (s3, t, e, i) => {
9812
- ui.lchown(s3, t, e, (r) => {
9809
+ var ui = (s3, t, e, i) => {
9810
+ mi.lchown(s3, t, e, (r) => {
9813
9811
  i(r && r?.code !== "ENOENT" ? r : null);
9814
9812
  });
9815
9813
  };
9816
- var $n = (s3, t, e, i, r) => {
9817
- if (t.isDirectory()) fs2(Ee.resolve(s3, t.name), e, i, (n) => {
9814
+ var Vn = (s3, t, e, i, r) => {
9815
+ if (t.isDirectory()) ds(Ee.resolve(s3, t.name), e, i, (n) => {
9818
9816
  if (n) return r(n);
9819
9817
  let o = Ee.resolve(s3, t.name);
9820
- di(o, e, i, r);
9818
+ ui(o, e, i, r);
9821
9819
  });
9822
9820
  else {
9823
9821
  let n = Ee.resolve(s3, t.name);
9824
- di(n, e, i, r);
9822
+ ui(n, e, i, r);
9825
9823
  }
9826
9824
  };
9827
- var fs2 = (s3, t, e, i) => {
9828
- ui.readdir(s3, { withFileTypes: true }, (r, n) => {
9825
+ var ds = (s3, t, e, i) => {
9826
+ mi.readdir(s3, { withFileTypes: true }, (r, n) => {
9829
9827
  if (r) {
9830
9828
  if (r.code === "ENOENT") return i();
9831
9829
  if (r.code !== "ENOTDIR" && r.code !== "ENOTSUP") return i(r);
9832
9830
  }
9833
- if (r || !n.length) return di(s3, t, e, i);
9831
+ if (r || !n.length) return ui(s3, t, e, i);
9834
9832
  let o = n.length, h = null, a = (l) => {
9835
9833
  if (!h) {
9836
9834
  if (l) return i(h = l);
9837
- if (--o === 0) return di(s3, t, e, i);
9835
+ if (--o === 0) return ui(s3, t, e, i);
9838
9836
  }
9839
9837
  };
9840
- for (let l of n) $n(s3, l, t, e, a);
9838
+ for (let l of n) Vn(s3, l, t, e, a);
9841
9839
  });
9842
9840
  };
9843
- var Xn = (s3, t, e, i) => {
9844
- t.isDirectory() && ds(Ee.resolve(s3, t.name), e, i), cs(Ee.resolve(s3, t.name), e, i);
9841
+ var $n = (s3, t, e, i) => {
9842
+ t.isDirectory() && us(Ee.resolve(s3, t.name), e, i), fs2(Ee.resolve(s3, t.name), e, i);
9845
9843
  };
9846
- var ds = (s3, t, e) => {
9844
+ var us = (s3, t, e) => {
9847
9845
  let i;
9848
9846
  try {
9849
- i = ui.readdirSync(s3, { withFileTypes: true });
9847
+ i = mi.readdirSync(s3, { withFileTypes: true });
9850
9848
  } catch (r) {
9851
9849
  let n = r;
9852
9850
  if (n?.code === "ENOENT") return;
9853
- if (n?.code === "ENOTDIR" || n?.code === "ENOTSUP") return cs(s3, t, e);
9851
+ if (n?.code === "ENOTDIR" || n?.code === "ENOTSUP") return fs2(s3, t, e);
9854
9852
  throw n;
9855
9853
  }
9856
- for (let r of i) Xn(s3, r, t, e);
9857
- return cs(s3, t, e);
9854
+ for (let r of i) $n(s3, r, t, e);
9855
+ return fs2(s3, t, e);
9858
9856
  };
9859
9857
  var we = class extends Error {
9860
9858
  path;
@@ -9879,41 +9877,41 @@ var wt = class extends Error {
9879
9877
  return "SymlinkError";
9880
9878
  }
9881
9879
  };
9882
- var jn = (s3, t) => {
9880
+ var qn = (s3, t) => {
9883
9881
  k.stat(s3, (e, i) => {
9884
9882
  (e || !i.isDirectory()) && (e = new we(s3, e?.code || "ENOTDIR")), t(e);
9885
9883
  });
9886
9884
  };
9887
- var fr = (s3, t, e) => {
9885
+ var cr = (s3, t, e) => {
9888
9886
  s3 = f(s3);
9889
9887
  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), S = (E, x) => {
9890
- E ? e(E) : x && a ? fs2(x, o, h, (_s) => S(_s)) : n ? k.chmod(s3, r, e) : e();
9888
+ E ? e(E) : x && a ? ds(x, o, h, (xe) => S(xe)) : n ? k.chmod(s3, r, e) : e();
9891
9889
  };
9892
- if (s3 === d) return jn(s3, S);
9893
- if (l) return qn.mkdir(s3, { mode: r, recursive: true }).then((E) => S(null, E ?? void 0), S);
9894
- let N = f(mi.relative(d, s3)).split("/");
9895
- us(d, N, r, c, d, void 0, S);
9890
+ if (s3 === d) return qn(s3, S);
9891
+ if (l) return Xn.mkdir(s3, { mode: r, recursive: true }).then((E) => S(null, E ?? void 0), S);
9892
+ let N = f(pi.relative(d, s3)).split("/");
9893
+ ms(d, N, r, c, d, void 0, S);
9896
9894
  };
9897
- var us = (s3, t, e, i, r, n, o) => {
9898
- if (!t.length) return o(null, n);
9899
- let h = t.shift(), a = f(mi.resolve(s3 + "/" + h));
9900
- k.mkdir(a, e, dr(a, t, e, i, r, n, o));
9895
+ var ms = (s3, t, e, i, r, n, o) => {
9896
+ if (t.length === 0) return o(null, n);
9897
+ let h = t.shift(), a = f(pi.resolve(s3 + "/" + h));
9898
+ k.mkdir(a, e, fr(a, t, e, i, r, n, o));
9901
9899
  };
9902
- var dr = (s3, t, e, i, r, n, o) => (h) => {
9900
+ var fr = (s3, t, e, i, r, n, o) => (h) => {
9903
9901
  h ? k.lstat(s3, (a, l) => {
9904
9902
  if (a) a.path = a.path && f(a.path), o(a);
9905
- else if (l.isDirectory()) us(s3, t, e, i, r, n, o);
9903
+ else if (l.isDirectory()) ms(s3, t, e, i, r, n, o);
9906
9904
  else if (i) k.unlink(s3, (c) => {
9907
9905
  if (c) return o(c);
9908
- k.mkdir(s3, e, dr(s3, t, e, i, r, n, o));
9906
+ k.mkdir(s3, e, fr(s3, t, e, i, r, n, o));
9909
9907
  });
9910
9908
  else {
9911
9909
  if (l.isSymbolicLink()) return o(new wt(s3, s3 + "/" + t.join("/")));
9912
9910
  o(h);
9913
9911
  }
9914
- }) : (n = n || s3, us(s3, t, e, i, r, n, o));
9912
+ }) : (n = n || s3, ms(s3, t, e, i, r, n, o));
9915
9913
  };
9916
- var Qn = (s3) => {
9914
+ var jn = (s3) => {
9917
9915
  let t = false, e;
9918
9916
  try {
9919
9917
  t = k.statSync(s3).isDirectory();
@@ -9923,53 +9921,53 @@ var Qn = (s3) => {
9923
9921
  if (!t) throw new we(s3, e ?? "ENOTDIR");
9924
9922
  }
9925
9923
  };
9926
- var ur = (s3, t) => {
9924
+ var dr = (s3, t) => {
9927
9925
  s3 = f(s3);
9928
9926
  let e = t.umask ?? 18, i = t.mode | 448, r = (i & e) !== 0, n = t.uid, o = t.gid, h = typeof n == "number" && typeof o == "number" && (n !== t.processUid || o !== t.processGid), a = t.preserve, l = t.unlink, c = f(t.cwd), d = (E) => {
9929
- E && h && ds(E, n, o), r && k.chmodSync(s3, i);
9927
+ E && h && us(E, n, o), r && k.chmodSync(s3, i);
9930
9928
  };
9931
- if (s3 === c) return Qn(c), d();
9929
+ if (s3 === c) return jn(c), d();
9932
9930
  if (a) return d(k.mkdirSync(s3, { mode: i, recursive: true }) ?? void 0);
9933
- let T = f(mi.relative(c, s3)).split("/"), N;
9931
+ let T = f(pi.relative(c, s3)).split("/"), N;
9934
9932
  for (let E = T.shift(), x = c; E && (x += "/" + E); E = T.shift()) {
9935
- x = f(mi.resolve(x));
9933
+ x = f(pi.resolve(x));
9936
9934
  try {
9937
9935
  k.mkdirSync(x, i), N = N || x;
9938
9936
  } catch {
9939
- let Os = k.lstatSync(x);
9940
- if (Os.isDirectory()) continue;
9937
+ let xe = k.lstatSync(x);
9938
+ if (xe.isDirectory()) continue;
9941
9939
  if (l) {
9942
9940
  k.unlinkSync(x), k.mkdirSync(x, i), N = N || x;
9943
9941
  continue;
9944
- } else if (Os.isSymbolicLink()) return new wt(x, x + "/" + T.join("/"));
9942
+ } else if (xe.isSymbolicLink()) return new wt(x, x + "/" + T.join("/"));
9945
9943
  }
9946
9944
  }
9947
9945
  return d(N);
9948
9946
  };
9949
- var ms = /* @__PURE__ */ Object.create(null);
9950
- var mr = 1e4;
9947
+ var ps = /* @__PURE__ */ Object.create(null);
9948
+ var ur = 1e4;
9951
9949
  var $t = /* @__PURE__ */ new Set();
9952
- var pr = (s3) => {
9953
- $t.has(s3) ? $t.delete(s3) : ms[s3] = s3.normalize("NFD").toLocaleLowerCase("en").toLocaleUpperCase("en"), $t.add(s3);
9954
- let t = ms[s3], e = $t.size - mr;
9955
- if (e > mr / 10) {
9956
- for (let i of $t) if ($t.delete(i), delete ms[i], --e <= 0) break;
9950
+ var mr = (s3) => {
9951
+ $t.has(s3) ? $t.delete(s3) : ps[s3] = s3.normalize("NFD").toLocaleLowerCase("en").toLocaleUpperCase("en"), $t.add(s3);
9952
+ let t = ps[s3], e = $t.size - ur;
9953
+ if (e > ur / 10) {
9954
+ for (let i of $t) if ($t.delete(i), delete ps[i], --e <= 0) break;
9957
9955
  }
9958
9956
  return t;
9959
9957
  };
9960
- var Jn = process.env.TESTING_TAR_FAKE_PLATFORM || process.platform;
9961
- var to = Jn === "win32";
9962
- var eo = (s3) => s3.split("/").slice(0, -1).reduce((e, i) => {
9963
- let r = e[e.length - 1];
9964
- return r !== void 0 && (i = Er(r, i)), e.push(i || "/"), e;
9958
+ var Qn = process.env.TESTING_TAR_FAKE_PLATFORM || process.platform;
9959
+ var Jn = Qn === "win32";
9960
+ var to = (s3) => s3.split("/").slice(0, -1).reduce((e, i) => {
9961
+ let r = e.at(-1);
9962
+ return r !== void 0 && (i = pr(r, i)), e.push(i || "/"), e;
9965
9963
  }, []);
9966
- var pi = class {
9964
+ var Ei = class {
9967
9965
  #t = /* @__PURE__ */ new Map();
9968
9966
  #i = /* @__PURE__ */ new Map();
9969
9967
  #s = /* @__PURE__ */ new Set();
9970
9968
  reserve(t, e) {
9971
- t = to ? ["win32 parallelization disabled"] : t.map((r) => mt(Er(pr(r))));
9972
- let i = new Set(t.map((r) => eo(r)).reduce((r, n) => r.concat(n)));
9969
+ t = Jn ? ["win32 parallelization disabled"] : t.map((r) => mt(pr(mr(r))));
9970
+ let i = new Set(t.map((r) => to(r)).reduce((r, n) => r.concat(n)));
9973
9971
  this.#i.set(e, { dirs: i, paths: t });
9974
9972
  for (let r of t) {
9975
9973
  let n = this.#t.get(r);
@@ -9979,7 +9977,7 @@ var pi = class {
9979
9977
  let n = this.#t.get(r);
9980
9978
  if (!n) this.#t.set(r, [/* @__PURE__ */ new Set([e])]);
9981
9979
  else {
9982
- let o = n[n.length - 1];
9980
+ let o = n.at(-1);
9983
9981
  o instanceof Set ? o.add(e) : n.push(/* @__PURE__ */ new Set([e]));
9984
9982
  }
9985
9983
  }
@@ -10027,55 +10025,55 @@ var pi = class {
10027
10025
  return this.#s.delete(t), n.forEach((o) => this.#r(o)), true;
10028
10026
  }
10029
10027
  };
10030
- var wr = () => process.umask();
10031
- var Sr = /* @__PURE__ */ Symbol("onEntry");
10032
- var Ss = /* @__PURE__ */ Symbol("checkFs");
10033
- var yr = /* @__PURE__ */ Symbol("checkFs2");
10034
- var ys = /* @__PURE__ */ Symbol("isReusable");
10028
+ var Er = () => process.umask();
10029
+ var wr = /* @__PURE__ */ Symbol("onEntry");
10030
+ var ys = /* @__PURE__ */ Symbol("checkFs");
10031
+ var Sr = /* @__PURE__ */ Symbol("checkFs2");
10032
+ var Rs = /* @__PURE__ */ Symbol("isReusable");
10035
10033
  var P = /* @__PURE__ */ Symbol("makeFs");
10036
- var Rs = /* @__PURE__ */ Symbol("file");
10037
- var bs = /* @__PURE__ */ Symbol("directory");
10038
- var wi = /* @__PURE__ */ Symbol("link");
10039
- var Rr = /* @__PURE__ */ Symbol("symlink");
10040
- var br = /* @__PURE__ */ Symbol("hardlink");
10034
+ var bs = /* @__PURE__ */ Symbol("file");
10035
+ var _s = /* @__PURE__ */ Symbol("directory");
10036
+ var Si = /* @__PURE__ */ Symbol("link");
10037
+ var yr = /* @__PURE__ */ Symbol("symlink");
10038
+ var Rr = /* @__PURE__ */ Symbol("hardlink");
10041
10039
  var ye = /* @__PURE__ */ Symbol("ensureNoSymlink");
10042
- var gr = /* @__PURE__ */ Symbol("unsupported");
10040
+ var br = /* @__PURE__ */ Symbol("unsupported");
10043
10041
  var _r = /* @__PURE__ */ Symbol("checkPath");
10044
- var ps = /* @__PURE__ */ Symbol("stripAbsolutePath");
10042
+ var Es = /* @__PURE__ */ Symbol("stripAbsolutePath");
10045
10043
  var St = /* @__PURE__ */ Symbol("mkdir");
10046
10044
  var O = /* @__PURE__ */ Symbol("onError");
10047
- var Ei = /* @__PURE__ */ Symbol("pending");
10048
- var Or = /* @__PURE__ */ Symbol("pend");
10045
+ var wi = /* @__PURE__ */ Symbol("pending");
10046
+ var gr = /* @__PURE__ */ Symbol("pend");
10049
10047
  var Xt = /* @__PURE__ */ Symbol("unpend");
10050
- var Es = /* @__PURE__ */ Symbol("ended");
10051
- var ws = /* @__PURE__ */ Symbol("maybeClose");
10048
+ var ws = /* @__PURE__ */ Symbol("ended");
10049
+ var Ss = /* @__PURE__ */ Symbol("maybeClose");
10052
10050
  var gs = /* @__PURE__ */ Symbol("skip");
10053
10051
  var Re = /* @__PURE__ */ Symbol("doChown");
10054
10052
  var be = /* @__PURE__ */ Symbol("uid");
10055
- var ge = /* @__PURE__ */ Symbol("gid");
10056
- var _e = /* @__PURE__ */ Symbol("checkedCwd");
10057
- var so = process.env.TESTING_TAR_FAKE_PLATFORM || process.platform;
10058
- var Oe = so === "win32";
10059
- var ro = 1024;
10060
- var no = (s3, t) => {
10053
+ var _e = /* @__PURE__ */ Symbol("gid");
10054
+ var ge = /* @__PURE__ */ Symbol("checkedCwd");
10055
+ var io = process.env.TESTING_TAR_FAKE_PLATFORM || process.platform;
10056
+ var Oe = io === "win32";
10057
+ var so = 1024;
10058
+ var ro = (s3, t) => {
10061
10059
  if (!Oe) return u.unlink(s3, t);
10062
- let e = s3 + ".DELETE." + xr(16).toString("hex");
10060
+ let e = s3 + ".DELETE." + Tr(16).toString("hex");
10063
10061
  u.rename(s3, e, (i) => {
10064
10062
  if (i) return t(i);
10065
10063
  u.unlink(e, t);
10066
10064
  });
10067
10065
  };
10068
- var oo = (s3) => {
10066
+ var no = (s3) => {
10069
10067
  if (!Oe) return u.unlinkSync(s3);
10070
- let t = s3 + ".DELETE." + xr(16).toString("hex");
10068
+ let t = s3 + ".DELETE." + Tr(16).toString("hex");
10071
10069
  u.renameSync(s3, t), u.unlinkSync(t);
10072
10070
  };
10073
- var Tr = (s3, t, e) => s3 !== void 0 && s3 === s3 >>> 0 ? s3 : t !== void 0 && t === t >>> 0 ? t : e;
10071
+ var Or = (s3, t, e) => s3 !== void 0 && s3 === s3 >>> 0 ? s3 : t !== void 0 && t === t >>> 0 ? t : e;
10074
10072
  var qt = class extends st {
10075
- [Es] = false;
10076
- [_e] = false;
10077
- [Ei] = 0;
10078
- reservations = new pi();
10073
+ [ws] = false;
10074
+ [ge] = false;
10075
+ [wi] = 0;
10076
+ reservations = new Ei();
10079
10077
  transform;
10080
10078
  writable = true;
10081
10079
  readable = false;
@@ -10102,30 +10100,28 @@ var qt = class extends st {
10102
10100
  chmod;
10103
10101
  constructor(t = {}) {
10104
10102
  if (t.ondone = () => {
10105
- this[Es] = true, this[ws]();
10103
+ this[ws] = true, this[Ss]();
10106
10104
  }, super(t), this.transform = t.transform, this.chmod = !!t.chmod, typeof t.uid == "number" || typeof t.gid == "number") {
10107
10105
  if (typeof t.uid != "number" || typeof t.gid != "number") throw new TypeError("cannot set owner without number uid and gid");
10108
10106
  if (t.preserveOwner) throw new TypeError("cannot preserve owner in archive and also set owner explicitly");
10109
10107
  this.uid = t.uid, this.gid = t.gid, this.setOwner = true;
10110
10108
  } else this.uid = void 0, this.gid = void 0, this.setOwner = false;
10111
- t.preserveOwner === void 0 && typeof t.uid != "number" ? this.preserveOwner = !!(process.getuid && process.getuid() === 0) : this.preserveOwner = !!t.preserveOwner, this.processUid = (this.preserveOwner || this.setOwner) && process.getuid ? process.getuid() : void 0, this.processGid = (this.preserveOwner || this.setOwner) && process.getgid ? process.getgid() : void 0, this.maxDepth = typeof t.maxDepth == "number" ? t.maxDepth : ro, this.forceChown = t.forceChown === true, this.win32 = !!t.win32 || Oe, this.newer = !!t.newer, this.keep = !!t.keep, this.noMtime = !!t.noMtime, this.preservePaths = !!t.preservePaths, this.unlink = !!t.unlink, this.cwd = f(R.resolve(t.cwd || process.cwd())), this.strip = Number(t.strip) || 0, this.processUmask = this.chmod ? typeof t.processUmask == "number" ? t.processUmask : wr() : 0, this.umask = typeof t.umask == "number" ? t.umask : this.processUmask, this.dmode = t.dmode || 511 & ~this.umask, this.fmode = t.fmode || 438 & ~this.umask, this.on("entry", (e) => this[Sr](e));
10109
+ this.preserveOwner = t.preserveOwner === void 0 && typeof t.uid != "number" ? !!(process.getuid && process.getuid() === 0) : !!t.preserveOwner, this.processUid = (this.preserveOwner || this.setOwner) && process.getuid ? process.getuid() : void 0, this.processGid = (this.preserveOwner || this.setOwner) && process.getgid ? process.getgid() : void 0, this.maxDepth = typeof t.maxDepth == "number" ? t.maxDepth : so, this.forceChown = t.forceChown === true, this.win32 = !!t.win32 || Oe, this.newer = !!t.newer, this.keep = !!t.keep, this.noMtime = !!t.noMtime, this.preservePaths = !!t.preservePaths, this.unlink = !!t.unlink, this.cwd = f(R.resolve(t.cwd || process.cwd())), this.strip = Number(t.strip) || 0, this.processUmask = this.chmod ? typeof t.processUmask == "number" ? t.processUmask : Er() : 0, this.umask = typeof t.umask == "number" ? t.umask : this.processUmask, this.dmode = t.dmode || 511 & ~this.umask, this.fmode = t.fmode || 438 & ~this.umask, this.on("entry", (e) => this[wr](e));
10112
10110
  }
10113
10111
  warn(t, e, i = {}) {
10114
10112
  return (t === "TAR_BAD_ARCHIVE" || t === "TAR_ABORT") && (i.recoverable = false), super.warn(t, e, i);
10115
10113
  }
10116
- [ws]() {
10117
- this[Es] && this[Ei] === 0 && (this.emit("prefinish"), this.emit("finish"), this.emit("end"));
10114
+ [Ss]() {
10115
+ this[ws] && this[wi] === 0 && (this.emit("prefinish"), this.emit("finish"), this.emit("end"));
10118
10116
  }
10119
- [ps](t, e) {
10117
+ [Es](t, e) {
10120
10118
  let i = t[e], { type: r } = t;
10121
10119
  if (!i || this.preservePaths) return true;
10122
- let [n, o] = ce(i), h = o.replace(/\\/g, "/").split("/");
10120
+ let [n, o] = ce(i), h = o.replaceAll(/\\/g, "/").split("/");
10123
10121
  if (h.includes("..") || Oe && /^[a-z]:\.\.$/i.test(h[0] ?? "")) {
10124
10122
  if (e === "path" || r === "Link") return this.warn("TAR_ENTRY_ERROR", `${e} contains '..'`, { entry: t, [e]: i }), false;
10125
- {
10126
- let a = R.posix.dirname(t.path), l = R.posix.normalize(R.posix.join(a, h.join("/")));
10127
- if (l.startsWith("../") || l === "..") return this.warn("TAR_ENTRY_ERROR", `${e} escapes extraction directory`, { entry: t, [e]: i }), false;
10128
- }
10123
+ let a = R.posix.dirname(t.path), l = R.posix.normalize(R.posix.join(a, h.join("/")));
10124
+ if (l.startsWith("../") || l === "..") return this.warn("TAR_ENTRY_ERROR", `${e} escapes extraction directory`, { entry: t, [e]: i }), false;
10129
10125
  }
10130
10126
  return n && (t[e] = String(o), this.warn("TAR_ENTRY_INFO", `stripping ${n} from absolute ${e}`, { entry: t, [e]: i })), true;
10131
10127
  }
@@ -10141,20 +10137,20 @@ var qt = class extends st {
10141
10137
  i.splice(0, this.strip), t.path = i.join("/");
10142
10138
  }
10143
10139
  if (isFinite(this.maxDepth) && i.length > this.maxDepth) return this.warn("TAR_ENTRY_ERROR", "path excessively deep", { entry: t, path: e, depth: i.length, maxDepth: this.maxDepth }), false;
10144
- if (!this[ps](t, "path") || !this[ps](t, "linkpath")) return false;
10145
- if (R.isAbsolute(t.path) ? t.absolute = f(R.resolve(t.path)) : t.absolute = f(R.resolve(this.cwd, t.path)), !this.preservePaths && typeof t.absolute == "string" && t.absolute.indexOf(this.cwd + "/") !== 0 && t.absolute !== this.cwd) return this.warn("TAR_ENTRY_ERROR", "path escaped extraction target", { entry: t, path: f(t.path), resolvedPath: t.absolute, cwd: this.cwd }), false;
10140
+ if (!this[Es](t, "path") || !this[Es](t, "linkpath")) return false;
10141
+ if (t.absolute = R.isAbsolute(t.path) ? f(R.resolve(t.path)) : f(R.resolve(this.cwd, t.path)), !this.preservePaths && typeof t.absolute == "string" && t.absolute.indexOf(this.cwd + "/") !== 0 && t.absolute !== this.cwd) return this.warn("TAR_ENTRY_ERROR", "path escaped extraction target", { entry: t, path: f(t.path), resolvedPath: t.absolute, cwd: this.cwd }), false;
10146
10142
  if (t.absolute === this.cwd && t.type !== "Directory" && t.type !== "GNUDumpDir") return false;
10147
10143
  if (this.win32) {
10148
10144
  let { root: r } = R.win32.parse(String(t.absolute));
10149
- t.absolute = r + $i(String(t.absolute).slice(r.length));
10145
+ t.absolute = r + Xi(String(t.absolute).slice(r.length));
10150
10146
  let { root: n } = R.win32.parse(t.path);
10151
- t.path = n + $i(t.path.slice(n.length));
10147
+ t.path = n + Xi(t.path.slice(n.length));
10152
10148
  }
10153
10149
  return true;
10154
10150
  }
10155
- [Sr](t) {
10151
+ [wr](t) {
10156
10152
  if (!this[_r](t)) return t.resume();
10157
- switch (io.equal(typeof t.absolute, "string"), t.type) {
10153
+ switch (eo.equal(typeof t.absolute, "string"), t.type) {
10158
10154
  case "Directory":
10159
10155
  case "GNUDumpDir":
10160
10156
  t.mode && (t.mode = t.mode | 448);
@@ -10163,28 +10159,28 @@ var qt = class extends st {
10163
10159
  case "ContiguousFile":
10164
10160
  case "Link":
10165
10161
  case "SymbolicLink":
10166
- return this[Ss](t);
10162
+ return this[ys](t);
10167
10163
  default:
10168
- return this[gr](t);
10164
+ return this[br](t);
10169
10165
  }
10170
10166
  }
10171
10167
  [O](t, e) {
10172
10168
  t.name === "CwdError" ? this.emit("error", t) : (this.warn("TAR_ENTRY_ERROR", t, { entry: e }), this[Xt](), e.resume());
10173
10169
  }
10174
10170
  [St](t, e, i) {
10175
- fr(f(t), { uid: this.uid, gid: this.gid, processUid: this.processUid, processGid: this.processGid, umask: this.processUmask, preserve: this.preservePaths, unlink: this.unlink, cwd: this.cwd, mode: e }, i);
10171
+ cr(f(t), { uid: this.uid, gid: this.gid, processUid: this.processUid, processGid: this.processGid, umask: this.processUmask, preserve: this.preservePaths, unlink: this.unlink, cwd: this.cwd, mode: e }, i);
10176
10172
  }
10177
10173
  [Re](t) {
10178
10174
  return this.forceChown || this.preserveOwner && (typeof t.uid == "number" && t.uid !== this.processUid || typeof t.gid == "number" && t.gid !== this.processGid) || typeof this.uid == "number" && this.uid !== this.processUid || typeof this.gid == "number" && this.gid !== this.processGid;
10179
10175
  }
10180
10176
  [be](t) {
10181
- return Tr(this.uid, t.uid, this.processUid);
10177
+ return Or(this.uid, t.uid, this.processUid);
10182
10178
  }
10183
- [ge](t) {
10184
- return Tr(this.gid, t.gid, this.processGid);
10179
+ [_e](t) {
10180
+ return Or(this.gid, t.gid, this.processGid);
10185
10181
  }
10186
- [Rs](t, e) {
10187
- let i = typeof t.mode == "number" ? t.mode & 4095 : this.fmode, r = new tt2(String(t.absolute), { flags: ls(t.size), mode: i, autoClose: false });
10182
+ [bs](t, e) {
10183
+ let i = typeof t.mode == "number" ? t.mode & 4095 : this.fmode, r = new tt2(String(t.absolute), { flags: cs(t.size), mode: i, autoClose: false });
10188
10184
  r.on("error", (a) => {
10189
10185
  r.fd && u.close(r.fd, () => {
10190
10186
  }), r.write = () => true, this[O](a, t), e();
@@ -10208,7 +10204,7 @@ var qt = class extends st {
10208
10204
  }
10209
10205
  if (typeof l == "number" && this[Re](t)) {
10210
10206
  n++;
10211
- let c = this[be](t), d = this[ge](t);
10207
+ let c = this[be](t), d = this[_e](t);
10212
10208
  typeof c == "number" && typeof d == "number" && u.fchown(l, c, d, (S) => S ? u.chown(a, c, d, (T) => o(T && S)) : o());
10213
10209
  }
10214
10210
  o();
@@ -10218,7 +10214,7 @@ var qt = class extends st {
10218
10214
  this[O](a, t), e();
10219
10215
  }), t.pipe(h)), h.pipe(r);
10220
10216
  }
10221
- [bs](t, e) {
10217
+ [_s](t, e) {
10222
10218
  let i = typeof t.mode == "number" ? t.mode & 4095 : this.dmode;
10223
10219
  this[St](String(t.absolute), i, (r) => {
10224
10220
  if (r) {
@@ -10228,21 +10224,21 @@ var qt = class extends st {
10228
10224
  let n = 1, o = () => {
10229
10225
  --n === 0 && (e(), this[Xt](), t.resume());
10230
10226
  };
10231
- t.mtime && !this.noMtime && (n++, u.utimes(String(t.absolute), t.atime || /* @__PURE__ */ new Date(), t.mtime, o)), this[Re](t) && (n++, u.chown(String(t.absolute), Number(this[be](t)), Number(this[ge](t)), o)), o();
10227
+ t.mtime && !this.noMtime && (n++, u.utimes(String(t.absolute), t.atime || /* @__PURE__ */ new Date(), t.mtime, o)), this[Re](t) && (n++, u.chown(String(t.absolute), Number(this[be](t)), Number(this[_e](t)), o)), o();
10232
10228
  });
10233
10229
  }
10234
- [gr](t) {
10230
+ [br](t) {
10235
10231
  t.unsupported = true, this.warn("TAR_ENTRY_UNSUPPORTED", `unsupported entry type: ${t.type}`, { entry: t }), t.resume();
10236
10232
  }
10237
- [Rr](t, e) {
10233
+ [yr](t, e) {
10238
10234
  let i = f(R.relative(this.cwd, R.resolve(R.dirname(String(t.absolute)), String(t.linkpath)))).split("/");
10239
- this[ye](t, this.cwd, i, () => this[wi](t, String(t.linkpath), "symlink", e), (r) => {
10235
+ this[ye](t, this.cwd, i, () => this[Si](t, String(t.linkpath), "symlink", e), (r) => {
10240
10236
  this[O](r, t), e();
10241
10237
  });
10242
10238
  }
10243
- [br](t, e) {
10239
+ [Rr](t, e) {
10244
10240
  let i = f(R.resolve(this.cwd, String(t.linkpath))), r = f(String(t.linkpath)).split("/");
10245
- this[ye](t, this.cwd, r, () => this[wi](t, i, "link", e), (n) => {
10241
+ this[ye](t, this.cwd, r, () => this[Si](t, i, "link", e), (n) => {
10246
10242
  this[O](n, t), e();
10247
10243
  });
10248
10244
  }
@@ -10256,24 +10252,24 @@ var qt = class extends st {
10256
10252
  this[ye](t, h, i, r, n);
10257
10253
  });
10258
10254
  }
10259
- [Or]() {
10260
- this[Ei]++;
10255
+ [gr]() {
10256
+ this[wi]++;
10261
10257
  }
10262
10258
  [Xt]() {
10263
- this[Ei]--, this[ws]();
10259
+ this[wi]--, this[Ss]();
10264
10260
  }
10265
10261
  [gs](t) {
10266
10262
  this[Xt](), t.resume();
10267
10263
  }
10268
- [ys](t, e) {
10264
+ [Rs](t, e) {
10269
10265
  return t.type === "File" && !this.unlink && e.isFile() && e.nlink <= 1 && !Oe;
10270
10266
  }
10271
- [Ss](t) {
10272
- this[Or]();
10267
+ [ys](t) {
10268
+ this[gr]();
10273
10269
  let e = [t.path];
10274
- t.linkpath && e.push(t.linkpath), this.reservations.reserve(e, (i) => this[yr](t, i));
10270
+ t.linkpath && e.push(t.linkpath), this.reservations.reserve(e, (i) => this[Sr](t, i));
10275
10271
  }
10276
- [yr](t, e) {
10272
+ [Sr](t, e) {
10277
10273
  let i = (h) => {
10278
10274
  e(h);
10279
10275
  }, r = () => {
@@ -10282,7 +10278,7 @@ var qt = class extends st {
10282
10278
  this[O](h, t), i();
10283
10279
  return;
10284
10280
  }
10285
- this[_e] = true, n();
10281
+ this[ge] = true, n();
10286
10282
  });
10287
10283
  }, n = () => {
10288
10284
  if (t.absolute !== this.cwd) {
@@ -10302,7 +10298,7 @@ var qt = class extends st {
10302
10298
  this[gs](t), i();
10303
10299
  return;
10304
10300
  }
10305
- if (h || this[ys](t, a)) return this[P](null, t, i);
10301
+ if (h || this[Rs](t, a)) return this[P](null, t, i);
10306
10302
  if (a.isDirectory()) {
10307
10303
  if (t.type === "Directory") {
10308
10304
  let l = this.chmod && t.mode && (a.mode & 4095) !== t.mode, c = (d) => this[P](d ?? null, t, i);
@@ -10311,10 +10307,10 @@ var qt = class extends st {
10311
10307
  if (t.absolute !== this.cwd) return u.rmdir(String(t.absolute), (l) => this[P](l ?? null, t, i));
10312
10308
  }
10313
10309
  if (t.absolute === this.cwd) return this[P](null, t, i);
10314
- no(String(t.absolute), (l) => this[P](l ?? null, t, i));
10310
+ ro(String(t.absolute), (l) => this[P](l ?? null, t, i));
10315
10311
  });
10316
10312
  };
10317
- this[_e] ? n() : r();
10313
+ this[ge] ? n() : r();
10318
10314
  }
10319
10315
  [P](t, e, i) {
10320
10316
  if (t) {
@@ -10325,17 +10321,17 @@ var qt = class extends st {
10325
10321
  case "File":
10326
10322
  case "OldFile":
10327
10323
  case "ContiguousFile":
10328
- return this[Rs](e, i);
10324
+ return this[bs](e, i);
10329
10325
  case "Link":
10330
- return this[br](e, i);
10331
- case "SymbolicLink":
10332
10326
  return this[Rr](e, i);
10327
+ case "SymbolicLink":
10328
+ return this[yr](e, i);
10333
10329
  case "Directory":
10334
10330
  case "GNUDumpDir":
10335
- return this[bs](e, i);
10331
+ return this[_s](e, i);
10336
10332
  }
10337
10333
  }
10338
- [wi](t, e, i, r) {
10334
+ [Si](t, e, i, r) {
10339
10335
  u[i](e, String(t.absolute), (n) => {
10340
10336
  n ? this[O](n, t) : (this[Xt](), t.resume()), r();
10341
10337
  });
@@ -10354,11 +10350,11 @@ var Te = class extends qt {
10354
10350
  return super[P](t, e, () => {
10355
10351
  });
10356
10352
  }
10357
- [Ss](t) {
10358
- if (!this[_e]) {
10353
+ [ys](t) {
10354
+ if (!this[ge]) {
10359
10355
  let n = this[St](this.cwd, this.dmode);
10360
10356
  if (n) return this[O](n, t);
10361
- this[_e] = true;
10357
+ this[ge] = true;
10362
10358
  }
10363
10359
  if (t.absolute !== this.cwd) {
10364
10360
  let n = f(R.dirname(String(t.absolute)));
@@ -10369,7 +10365,7 @@ var Te = class extends qt {
10369
10365
  }
10370
10366
  let [e, i] = Se(() => u.lstatSync(String(t.absolute)));
10371
10367
  if (i && (this.keep || this.newer && i.mtime > (t.mtime ?? i.mtime))) return this[gs](t);
10372
- if (e || this[ys](t, i)) return this[P](null, t);
10368
+ if (e || this[Rs](t, i)) return this[P](null, t);
10373
10369
  if (i.isDirectory()) {
10374
10370
  if (t.type === "Directory") {
10375
10371
  let o = this.chmod && t.mode && (i.mode & 4095) !== t.mode, [h] = o ? Se(() => {
@@ -10380,10 +10376,10 @@ var Te = class extends qt {
10380
10376
  let [n] = Se(() => u.rmdirSync(String(t.absolute)));
10381
10377
  this[P](n, t);
10382
10378
  }
10383
- let [r] = t.absolute === this.cwd ? [] : Se(() => oo(String(t.absolute)));
10379
+ let [r] = t.absolute === this.cwd ? [] : Se(() => no(String(t.absolute)));
10384
10380
  this[P](r, t);
10385
10381
  }
10386
- [Rs](t, e) {
10382
+ [bs](t, e) {
10387
10383
  let i = typeof t.mode == "number" ? t.mode & 4095 : this.fmode, r = (h) => {
10388
10384
  let a;
10389
10385
  try {
@@ -10394,7 +10390,7 @@ var Te = class extends qt {
10394
10390
  (h || a) && this[O](h || a, t), e();
10395
10391
  }, n;
10396
10392
  try {
10397
- n = u.openSync(String(t.absolute), ls(t.size), i);
10393
+ n = u.openSync(String(t.absolute), cs(t.size), i);
10398
10394
  } catch (h) {
10399
10395
  return r(h);
10400
10396
  }
@@ -10420,7 +10416,7 @@ var Te = class extends qt {
10420
10416
  }
10421
10417
  }
10422
10418
  if (this[Re](t)) {
10423
- let a = this[be](t), l = this[ge](t);
10419
+ let a = this[be](t), l = this[_e](t);
10424
10420
  try {
10425
10421
  u.fchownSync(n, Number(a), Number(l));
10426
10422
  } catch (c) {
@@ -10434,7 +10430,7 @@ var Te = class extends qt {
10434
10430
  r(h);
10435
10431
  });
10436
10432
  }
10437
- [bs](t, e) {
10433
+ [_s](t, e) {
10438
10434
  let i = typeof t.mode == "number" ? t.mode & 4095 : this.dmode, r = this[St](String(t.absolute), i);
10439
10435
  if (r) {
10440
10436
  this[O](r, t), e();
@@ -10445,20 +10441,20 @@ var Te = class extends qt {
10445
10441
  } catch {
10446
10442
  }
10447
10443
  if (this[Re](t)) try {
10448
- u.chownSync(String(t.absolute), Number(this[be](t)), Number(this[ge](t)));
10444
+ u.chownSync(String(t.absolute), Number(this[be](t)), Number(this[_e](t)));
10449
10445
  } catch {
10450
10446
  }
10451
10447
  e(), t.resume();
10452
10448
  }
10453
10449
  [St](t, e) {
10454
10450
  try {
10455
- return ur(f(t), { uid: this.uid, gid: this.gid, processUid: this.processUid, processGid: this.processGid, umask: this.processUmask, preserve: this.preservePaths, unlink: this.unlink, cwd: this.cwd, mode: e });
10451
+ return dr(f(t), { uid: this.uid, gid: this.gid, processUid: this.processUid, processGid: this.processGid, umask: this.processUmask, preserve: this.preservePaths, unlink: this.unlink, cwd: this.cwd, mode: e });
10456
10452
  } catch (i) {
10457
10453
  return i;
10458
10454
  }
10459
10455
  }
10460
10456
  [ye](t, e, i, r, n) {
10461
- if (this.preservePaths || !i.length) return r();
10457
+ if (this.preservePaths || i.length === 0) return r();
10462
10458
  let o = e;
10463
10459
  for (let h of i) {
10464
10460
  o = R.resolve(o, h);
@@ -10468,7 +10464,7 @@ var Te = class extends qt {
10468
10464
  }
10469
10465
  r();
10470
10466
  }
10471
- [wi](t, e, i, r) {
10467
+ [Si](t, e, i, r) {
10472
10468
  let n = `${i}Sync`;
10473
10469
  try {
10474
10470
  u[n](e, String(t.absolute)), r(), t.resume();
@@ -10477,26 +10473,26 @@ var Te = class extends qt {
10477
10473
  }
10478
10474
  }
10479
10475
  };
10480
- var ho = (s3) => {
10481
- let t = new Te(s3), e = s3.file, i = Lr.statSync(e), r = s3.maxReadSize || 16 * 1024 * 1024;
10482
- new ve(e, { readSize: r, size: i.size }).pipe(t);
10476
+ var oo = (s3) => {
10477
+ let t = new Te(s3), e = s3.file, i = xr.statSync(e), r = s3.maxReadSize || 16 * 1024 * 1024;
10478
+ new Me(e, { readSize: r, size: i.size }).pipe(t);
10483
10479
  };
10484
- var ao = (s3, t) => {
10480
+ var ho = (s3, t) => {
10485
10481
  let e = new qt(s3), i = s3.maxReadSize || 16 * 1024 * 1024, r = s3.file;
10486
10482
  return new Promise((o, h) => {
10487
- e.on("error", h), e.on("close", o), Lr.stat(r, (a, l) => {
10483
+ e.on("error", h), e.on("close", o), xr.stat(r, (a, l) => {
10488
10484
  if (a) h(a);
10489
10485
  else {
10490
- let c = new gt(r, { readSize: i, size: l.size });
10486
+ let c = new _t(r, { readSize: i, size: l.size });
10491
10487
  c.on("error", h), c.pipe(e);
10492
10488
  }
10493
10489
  });
10494
10490
  });
10495
10491
  };
10496
- var lo = K(ho, ao, (s3) => new Te(s3), (s3) => new qt(s3), (s3, t) => {
10497
- t?.length && Yi(s3, t);
10492
+ var ao = K(oo, ho, (s3) => new Te(s3), (s3) => new qt(s3), (s3, t) => {
10493
+ t?.length && Ki(s3, t);
10498
10494
  });
10499
- var co = (s3, t) => {
10495
+ var lo = (s3, t) => {
10500
10496
  let e = new kt(s3), i = true, r, n;
10501
10497
  try {
10502
10498
  try {
@@ -10517,7 +10513,7 @@ var co = (s3, t) => {
10517
10513
  if (n + l + 512 > o.size) break;
10518
10514
  n += l, s3.mtimeCache && a.mtime && s3.mtimeCache.set(String(a.path), a.mtime);
10519
10515
  }
10520
- i = false, fo(s3, e, n, r, t);
10516
+ i = false, co(s3, e, n, r, t);
10521
10517
  } finally {
10522
10518
  if (i) try {
10523
10519
  v.closeSync(r);
@@ -10525,11 +10521,11 @@ var co = (s3, t) => {
10525
10521
  }
10526
10522
  }
10527
10523
  };
10528
- var fo = (s3, t, e, i, r) => {
10524
+ var co = (s3, t, e, i, r) => {
10529
10525
  let n = new Wt(s3.file, { fd: i, start: e });
10530
- t.pipe(n), mo(t, r);
10526
+ t.pipe(n), uo(t, r);
10531
10527
  };
10532
- var uo = (s3, t) => {
10528
+ var fo = (s3, t) => {
10533
10529
  t = Array.from(t);
10534
10530
  let e = new Et(s3), i = (n, o, h) => {
10535
10531
  let a = (T, N) => {
@@ -10537,7 +10533,7 @@ var uo = (s3, t) => {
10537
10533
  }, l = 0;
10538
10534
  if (o === 0) return a(null, 0);
10539
10535
  let c = 0, d = Buffer.alloc(512), S = (T, N) => {
10540
- if (T || typeof N > "u") return a(T);
10536
+ if (T || N === void 0) return a(T);
10541
10537
  if (c += N, c < 512 && N) return v.read(n, d, c, d.length - c, l + c, S);
10542
10538
  if (l === 0 && d[0] === 31 && d[1] === 139) return a(new Error("cannot append to compressed archives"));
10543
10539
  if (c < 512) return a(null, l);
@@ -10559,38 +10555,35 @@ var uo = (s3, t) => {
10559
10555
  i(c, S.size, (T, N) => {
10560
10556
  if (T) return o(T);
10561
10557
  let E = new tt2(s3.file, { fd: c, start: N });
10562
- e.pipe(E), E.on("error", o), E.on("close", n), po(e, t);
10558
+ e.pipe(E), E.on("error", o), E.on("close", n), mo(e, t);
10563
10559
  });
10564
10560
  });
10565
10561
  };
10566
10562
  v.open(s3.file, h, a);
10567
10563
  });
10568
10564
  };
10569
- var mo = (s3, t) => {
10565
+ var uo = (s3, t) => {
10570
10566
  t.forEach((e) => {
10571
- e.charAt(0) === "@" ? It({ file: Nr.resolve(s3.cwd, e.slice(1)), sync: true, noResume: true, onReadEntry: (i) => s3.add(i) }) : s3.add(e);
10567
+ e.charAt(0) === "@" ? It({ file: Lr.resolve(s3.cwd, e.slice(1)), sync: true, noResume: true, onReadEntry: (i) => s3.add(i) }) : s3.add(e);
10572
10568
  }), s3.end();
10573
10569
  };
10574
- var po = async (s3, t) => {
10575
- for (let e = 0; e < t.length; e++) {
10576
- let i = String(t[e]);
10577
- i.charAt(0) === "@" ? await It({ file: Nr.resolve(String(s3.cwd), i.slice(1)), noResume: true, onReadEntry: (r) => s3.add(r) }) : s3.add(i);
10578
- }
10570
+ var mo = async (s3, t) => {
10571
+ for (let e of t) e.charAt(0) === "@" ? await It({ file: Lr.resolve(String(s3.cwd), e.slice(1)), noResume: true, onReadEntry: (i) => s3.add(i) }) : s3.add(e);
10579
10572
  s3.end();
10580
10573
  };
10581
- var vt = K(co, uo, () => {
10574
+ var vt = K(lo, fo, () => {
10582
10575
  throw new TypeError("file is required");
10583
10576
  }, () => {
10584
10577
  throw new TypeError("file is required");
10585
10578
  }, (s3, t) => {
10586
- if (!ks(s3)) throw new TypeError("file is required");
10579
+ if (!Fs(s3)) throw new TypeError("file is required");
10587
10580
  if (s3.gzip || s3.brotli || s3.zstd || s3.file.endsWith(".br") || s3.file.endsWith(".tbr")) throw new TypeError("cannot append to compressed archives");
10588
10581
  if (!t?.length) throw new TypeError("no paths specified to add/replace");
10589
10582
  });
10590
- var Eo = K(vt.syncFile, vt.asyncFile, vt.syncNoFile, vt.asyncNoFile, (s3, t = []) => {
10591
- vt.validate?.(s3, t), wo(s3);
10583
+ var po = K(vt.syncFile, vt.asyncFile, vt.syncNoFile, vt.asyncNoFile, (s3, t = []) => {
10584
+ vt.validate?.(s3, t), Eo(s3);
10592
10585
  });
10593
- var wo = (s3) => {
10586
+ var Eo = (s3) => {
10594
10587
  let t = s3.filter;
10595
10588
  s3.mtimeCache || (s3.mtimeCache = /* @__PURE__ */ new Map()), s3.filter = t ? (e, i) => t(e, i) && !((s3.mtimeCache?.get(e) ?? i.mtime ?? 0) > (i.mtime ?? 0)) : (e, i) => !((s3.mtimeCache?.get(e) ?? i.mtime ?? 0) > (i.mtime ?? 0));
10596
10589
  };
@@ -11519,14 +11512,18 @@ var disallowed = [
11519
11512
  "https:",
11520
11513
  "link:"
11521
11514
  ];
11515
+ var allowedInDev = /* @__PURE__ */ new Set(["link:"]);
11522
11516
  var depFields = [
11523
11517
  "dependencies",
11524
11518
  "devDependencies",
11525
11519
  "peerDependencies",
11526
11520
  "optionalDependencies"
11527
11521
  ];
11528
- function getProtocol(version2) {
11522
+ function getProtocol(version2, field) {
11529
11523
  for (const protocol of disallowed) {
11524
+ if (field === "devDependencies" && allowedInDev.has(protocol)) {
11525
+ continue;
11526
+ }
11530
11527
  if (version2.startsWith(protocol)) {
11531
11528
  return protocol;
11532
11529
  }
@@ -11548,7 +11545,7 @@ function* noProtocolDependencies(pkg, pkgAst) {
11548
11545
  continue;
11549
11546
  }
11550
11547
  for (const [name, version2] of Object.entries(deps)) {
11551
- const protocol = getProtocol(version2);
11548
+ const protocol = getProtocol(version2, field);
11552
11549
  if (protocol) {
11553
11550
  const { line, column } = jsonLocation(pkgAst, "member", field, name);
11554
11551
  yield {