import CJS_COMPAT_NODE_URL from 'node:url';
import CJS_COMPAT_NODE_PATH from 'node:path';
import CJS_COMPAT_NODE_MODULE from "node:module";

const __filename = CJS_COMPAT_NODE_URL.fileURLToPath(import.meta.url);
const __dirname = CJS_COMPAT_NODE_PATH.dirname(__filename);
const require = CJS_COMPAT_NODE_MODULE.createRequire(import.meta.url);
// ------------------------------------------------------------
// end of CJS compatibility banner, injected by Storybook's esbuild configuration
// ------------------------------------------------------------
import {
  a as o,
  b as S,
  d as h,
  f as Ge
} from "./chunk-HRN2KQZP.js";

// ../node_modules/isexe/windows.js
var je = h((no, ke) => {
  ke.exports = Ne;
  Ne.sync = dn;
  var Re = S("fs");
  function ln(e, t) {
    var n = t.pathExt !== void 0 ? t.pathExt : process.env.PATHEXT;
    if (!n || (n = n.split(";"), n.indexOf("") !== -1))
      return !0;
    for (var r = 0; r < n.length; r++) {
      var i = n[r].toLowerCase();
      if (i && e.substr(-i.length).toLowerCase() === i)
        return !0;
    }
    return !1;
  }
  o(ln, "checkPathExt");
  function $e(e, t, n) {
    return !e.isSymbolicLink() && !e.isFile() ? !1 : ln(t, n);
  }
  o($e, "checkStat");
  function Ne(e, t, n) {
    Re.stat(e, function(r, i) {
      n(r, r ? !1 : $e(i, e, t));
    });
  }
  o(Ne, "isexe");
  function dn(e, t) {
    return $e(Re.statSync(e), e, t);
  }
  o(dn, "sync");
});

// ../node_modules/isexe/mode.js
var Me = h((oo, Fe) => {
  Fe.exports = Le;
  Le.sync = pn;
  var Be = S("fs");
  function Le(e, t, n) {
    Be.stat(e, function(r, i) {
      n(r, r ? !1 : Ue(i, t));
    });
  }
  o(Le, "isexe");
  function pn(e, t) {
    return Ue(Be.statSync(e), t);
  }
  o(pn, "sync");
  function Ue(e, t) {
    return e.isFile() && mn(e, t);
  }
  o(Ue, "checkStat");
  function mn(e, t) {
    var n = e.mode, r = e.uid, i = e.gid, s = t.uid !== void 0 ? t.uid : process.getuid && process.getuid(), a = t.gid !== void 0 ? t.gid : process.getgid && process.getgid(), c = parseInt("100", 8), u = parseInt("010", 8), f = parseInt("001", 8), l = c | u, p = n & f || n & u && i === a || n & c && r === s || n & l && s === 0;
    return p;
  }
  o(mn, "checkMode");
});

// ../node_modules/isexe/index.js
var De = h((ao, _e) => {
  var so = S("fs"), G;
  process.platform === "win32" || global.TESTING_WINDOWS ? G = je() : G = Me();
  _e.exports = W;
  W.sync = hn;
  function W(e, t, n) {
    if (typeof t == "function" && (n = t, t = {}), !n) {
      if (typeof Promise != "function")
        throw new TypeError("callback not provided");
      return new Promise(function(r, i) {
        W(e, t || {}, function(s, a) {
          s ? i(s) : r(a);
        });
      });
    }
    G(e, t || {}, function(r, i) {
      r && (r.code === "EACCES" || t && t.ignoreErrors) && (r = null, i = !1), n(r, i);
    });
  }
  o(W, "isexe");
  function hn(e, t) {
    try {
      return G.sync(e, t || {});
    } catch (n) {
      if (t && t.ignoreErrors || n.code === "EACCES")
        return !1;
      throw n;
    }
  }
  o(hn, "sync");
});

// ../node_modules/which/which.js
var Ve = h((uo, Xe) => {
  var w = process.platform === "win32" || process.env.OSTYPE === "cygwin" || process.env.OSTYPE === "msys", ze = S("path"), yn = w ? ";" : ":", qe = De(), We = /* @__PURE__ */ o((e) => Object.assign(new Error(`not found: ${e}`), { code: "ENOENT" }), "getNotFoundError"), He = /* @__PURE__ */ o((e, t) => {
    let n = t.colon || yn, r = e.match(/\//) || w && e.match(/\\/) ? [""] : [
      // windows always checks the cwd first
      ...w ? [process.cwd()] : [],
      ...(t.path || process.env.PATH || /* istanbul ignore next: very unusual */
      "").split(n)
    ], i = w ? t.pathExt || process.env.PATHEXT || ".EXE;.CMD;.BAT;.COM" : "", s = w ? i.split(n) : [""];
    return w && e.indexOf(".") !== -1 && s[0] !== "" && s.unshift(""), {
      pathEnv: r,
      pathExt: s,
      pathExtExe: i
    };
  }, "getPathInfo"), Ke = /* @__PURE__ */ o((e, t, n) => {
    typeof t == "function" && (n = t, t = {}), t || (t = {});
    let { pathEnv: r, pathExt: i, pathExtExe: s } = He(e, t), a = [], c = /* @__PURE__ */ o((f) => new Promise((l, p) => {
      if (f === r.length)
        return t.all && a.length ? l(a) : p(We(e));
      let d = r[f], y = /^".*"$/.test(d) ? d.slice(1, -1) : d, m = ze.join(y, e), g = !y && /^\.[\\\/]/.test(e) ? e.slice(0, 2) + m : m;
      l(u(g, f, 0));
    }), "step"), u = /* @__PURE__ */ o((f, l, p) => new Promise((d, y) => {
      if (p === i.length)
        return d(c(l + 1));
      let m = i[p];
      qe(f + m, { pathExt: s }, (g, x) => {
        if (!g && x)
          if (t.all)
            a.push(f + m);
          else
            return d(f + m);
        return d(u(f, l, p + 1));
      });
    }), "subStep");
    return n ? c(0).then((f) => n(null, f), n) : c(0);
  }, "which"), gn = /* @__PURE__ */ o((e, t) => {
    t = t || {};
    let { pathEnv: n, pathExt: r, pathExtExe: i } = He(e, t), s = [];
    for (let a = 0; a < n.length; a++) {
      let c = n[a], u = /^".*"$/.test(c) ? c.slice(1, -1) : c, f = ze.join(u, e), l = !u && /^\.[\\\/]/.test(e) ? e.slice(0, 2) + f : f;
      for (let p = 0; p < r.length; p++) {
        let d = l + r[p];
        try {
          if (qe.sync(d, { pathExt: i }))
            if (t.all)
              s.push(d);
            else
              return d;
        } catch {
        }
      }
    }
    if (t.all && s.length)
      return s;
    if (t.nothrow)
      return null;
    throw We(e);
  }, "whichSync");
  Xe.exports = Ke;
  Ke.sync = gn;
});

// ../node_modules/path-key/index.js
var Ze = h((lo, H) => {
  "use strict";
  var Ye = /* @__PURE__ */ o((e = {}) => {
    let t = e.env || process.env;
    return (e.platform || process.platform) !== "win32" ? "PATH" : Object.keys(t).reverse().find((r) => r.toUpperCase() === "PATH") || "Path";
  }, "pathKey");
  H.exports = Ye;
  H.exports.default = Ye;
});

// ../node_modules/cross-spawn/lib/util/resolveCommand.js
var tt = h((mo, et) => {
  "use strict";
  var Qe = S("path"), Sn = Ve(), bn = Ze();
  function Je(e, t) {
    let n = e.options.env || process.env, r = process.cwd(), i = e.options.cwd != null, s = i && process.chdir !== void 0 && !process.chdir.disabled;
    if (s)
      try {
        process.chdir(e.options.cwd);
      } catch {
      }
    let a;
    try {
      a = Sn.sync(e.command, {
        path: n[bn({ env: n })],
        pathExt: t ? Qe.delimiter : void 0
      });
    } catch {
    } finally {
      s && process.chdir(r);
    }
    return a && (a = Qe.resolve(i ? e.options.cwd : "", a)), a;
  }
  o(Je, "resolveCommandAttempt");
  function xn(e) {
    return Je(e) || Je(e, !0);
  }
  o(xn, "resolveCommand");
  et.exports = xn;
});

// ../node_modules/cross-spawn/lib/util/escape.js
var nt = h((yo, X) => {
  "use strict";
  var K = /([()\][%!^"`<>&|;, *?])/g;
  function wn(e) {
    return e = e.replace(K, "^$1"), e;
  }
  o(wn, "escapeCommand");
  function En(e, t) {
    return e = `${e}`, e = e.replace(/(?=(\\+?)?)\1"/g, '$1$1\\"'), e = e.replace(/(?=(\\+?)?)\1$/, "$1$1"), e = `"${e}"`, e = e.replace(K, "^$1"), t && (e = e.replace(K, "^$1")), e;
  }
  o(En, "escapeArgument");
  X.exports.command = wn;
  X.exports.argument = En;
});

// ../node_modules/shebang-regex/index.js
var ot = h((So, rt) => {
  "use strict";
  rt.exports = /^#!(.*)/;
});

// ../node_modules/shebang-command/index.js
var st = h((bo, it) => {
  "use strict";
  var Tn = ot();
  it.exports = (e = "") => {
    let t = e.match(Tn);
    if (!t)
      return null;
    let [n, r] = t[0].replace(/#! ?/, "").split(" "), i = n.split("/").pop();
    return i === "env" ? r : r ? `${i} ${r}` : i;
  };
});

// ../node_modules/cross-spawn/lib/util/readShebang.js
var ct = h((xo, at) => {
  "use strict";
  var V = S("fs"), An = st();
  function Cn(e) {
    let n = Buffer.alloc(150), r;
    try {
      r = V.openSync(e, "r"), V.readSync(r, n, 0, 150, 0), V.closeSync(r);
    } catch {
    }
    return An(n.toString());
  }
  o(Cn, "readShebang");
  at.exports = Cn;
});

// ../node_modules/cross-spawn/lib/parse.js
var dt = h((Eo, lt) => {
  "use strict";
  var In = S("path"), ut = tt(), ft = nt(), Pn = ct(), vn = process.platform === "win32", On = /\.(?:com|exe)$/i, Gn = /node_modules[\\/].bin[\\/][^\\/]+\.cmd$/i;
  function Rn(e) {
    e.file = ut(e);
    let t = e.file && Pn(e.file);
    return t ? (e.args.unshift(e.file), e.command = t, ut(e)) : e.file;
  }
  o(Rn, "detectShebang");
  function $n(e) {
    if (!vn)
      return e;
    let t = Rn(e), n = !On.test(t);
    if (e.options.forceShell || n) {
      let r = Gn.test(t);
      e.command = In.normalize(e.command), e.command = ft.command(e.command), e.args = e.args.map((s) => ft.argument(s, r));
      let i = [e.command].concat(e.args).join(" ");
      e.args = ["/d", "/s", "/c", `"${i}"`], e.command = process.env.comspec || "cmd.exe", e.options.windowsVerbatimArguments = !0;
    }
    return e;
  }
  o($n, "parseNonShell");
  function Nn(e, t, n) {
    t && !Array.isArray(t) && (n = t, t = null), t = t ? t.slice(0) : [], n = Object.assign({}, n);
    let r = {
      command: e,
      args: t,
      options: n,
      file: void 0,
      original: {
        command: e,
        args: t
      }
    };
    return n.shell ? r : $n(r);
  }
  o(Nn, "parse");
  lt.exports = Nn;
});

// ../node_modules/cross-spawn/lib/enoent.js
var ht = h((Ao, mt) => {
  "use strict";
  var Y = process.platform === "win32";
  function Z(e, t) {
    return Object.assign(new Error(`${t} ${e.command} ENOENT`), {
      code: "ENOENT",
      errno: "ENOENT",
      syscall: `${t} ${e.command}`,
      path: e.command,
      spawnargs: e.args
    });
  }
  o(Z, "notFoundError");
  function kn(e, t) {
    if (!Y)
      return;
    let n = e.emit;
    e.emit = function(r, i) {
      if (r === "exit") {
        let s = pt(i, t);
        if (s)
          return n.call(e, "error", s);
      }
      return n.apply(e, arguments);
    };
  }
  o(kn, "hookChildProcess");
  function pt(e, t) {
    return Y && e === 1 && !t.file ? Z(t.original, "spawn") : null;
  }
  o(pt, "verifyENOENT");
  function jn(e, t) {
    return Y && e === 1 && !t.file ? Z(t.original, "spawnSync") : null;
  }
  o(jn, "verifyENOENTSync");
  mt.exports = {
    hookChildProcess: kn,
    verifyENOENT: pt,
    verifyENOENTSync: jn,
    notFoundError: Z
  };
});

// ../node_modules/cross-spawn/index.js
var St = h((Io, E) => {
  "use strict";
  var yt = S("child_process"), Q = dt(), J = ht();
  function gt(e, t, n) {
    let r = Q(e, t, n), i = yt.spawn(r.command, r.args, r.options);
    return J.hookChildProcess(i, r), i;
  }
  o(gt, "spawn");
  function Bn(e, t, n) {
    let r = Q(e, t, n), i = yt.spawnSync(r.command, r.args, r.options);
    return i.error = i.error || J.verifyENOENTSync(i.status, r), i;
  }
  o(Bn, "spawnSync");
  E.exports = gt;
  E.exports.spawn = gt;
  E.exports.sync = Bn;
  E.exports._parse = Q;
  E.exports._enoent = J;
});

// ../node_modules/merge-stream/index.js
var Wt = h((Qi, qt) => {
  "use strict";
  var { PassThrough: kr } = S("stream");
  qt.exports = function() {
    var e = [], t = new kr({ objectMode: !0 });
    return t.setMaxListeners(0), t.add = n, t.isEmpty = r, t.on("unpipe", i), Array.prototype.slice.call(arguments).forEach(n), t;
    function n(s) {
      return Array.isArray(s) ? (s.forEach(n), this) : (e.push(s), s.once("end", i.bind(null, s)), s.once("error", t.emit.bind(t, "error")), s.pipe(t, { end: !1 }), this);
    }
    o(n, "add");
    function r() {
      return e.length == 0;
    }
    o(r, "isEmpty");
    function i(s) {
      e = e.filter(function(a) {
        return a !== s;
      }), !e.length && t.readable && t.end();
    }
    o(i, "remove");
  };
});

// node_modules/execa/index.js
var sn = Ge(St(), 1);
import { Buffer as Zr } from "node:buffer";
import Qr from "node:path";
import Ce from "node:child_process";
import q from "node:process";

// ../node_modules/strip-final-newline/index.js
function ee(e) {
  let t = typeof e == "string" ? `
` : 10, n = typeof e == "string" ? "\r" : 13;
  return e[e.length - 1] === t && (e = e.slice(0, -1)), e[e.length - 1] === n && (e = e.slice(0, -1)), e;
}
o(ee, "stripFinalNewline");

// node_modules/npm-run-path/index.js
import $ from "node:process";
import T from "node:path";
import { fileURLToPath as bt } from "node:url";

// node_modules/path-key/index.js
function R(e = {}) {
  let {
    env: t = process.env,
    platform: n = process.platform
  } = e;
  return n !== "win32" ? "PATH" : Object.keys(t).reverse().find((r) => r.toUpperCase() === "PATH") || "Path";
}
o(R, "pathKey");

// node_modules/npm-run-path/index.js
var Ln = /* @__PURE__ */ o(({
  cwd: e = $.cwd(),
  path: t = $.env[R()],
  preferLocal: n = !0,
  execPath: r = $.execPath,
  addExecPath: i = !0
} = {}) => {
  let s = e instanceof URL ? bt(e) : e, a = T.resolve(s), c = [];
  return n && Un(c, a), i && Fn(c, r, a), [...c, t].join(T.delimiter);
}, "npmRunPath"), Un = /* @__PURE__ */ o((e, t) => {
  let n;
  for (; n !== t; )
    e.push(T.join(t, "node_modules/.bin")), n = t, t = T.resolve(t, "..");
}, "applyPreferLocal"), Fn = /* @__PURE__ */ o((e, t, n) => {
  let r = t instanceof URL ? bt(t) : t;
  e.push(T.resolve(n, r, ".."));
}, "applyExecPath"), xt = /* @__PURE__ */ o(({ env: e = $.env, ...t } = {}) => {
  e = { ...e };
  let n = R({ env: e });
  return t.path = e[n], e[n] = Ln(t), e;
}, "npmRunPathEnv");

// node_modules/mimic-fn/index.js
var Mn = /* @__PURE__ */ o((e, t, n, r) => {
  if (n === "length" || n === "prototype" || n === "arguments" || n === "caller")
    return;
  let i = Object.getOwnPropertyDescriptor(e, n), s = Object.getOwnPropertyDescriptor(t, n);
  !_n(i, s) && r || Object.defineProperty(e, n, s);
}, "copyProperty"), _n = /* @__PURE__ */ o(function(e, t) {
  return e === void 0 || e.configurable || e.writable === t.writable && e.enumerable === t.enumerable && e.configurable === t.configurable && (e.writable || e.value === t.value);
}, "canCopyProperty"), Dn = /* @__PURE__ */ o((e, t) => {
  let n = Object.getPrototypeOf(t);
  n !== Object.getPrototypeOf(e) && Object.setPrototypeOf(e, n);
}, "changePrototype"), zn = /* @__PURE__ */ o((e, t) => `/* Wrapped ${e}*/
${t}`, "wrappedToString"), qn = Object.getOwnPropertyDescriptor(Function.prototype, "toString"), Wn = Object.getOwnPropertyDescriptor(Function.prototype.toString, "name"), Hn = /* @__PURE__ */ o((e, t, n) => {
  let r = n === "" ? "" : `with ${n.trim()}() `, i = zn.bind(null, r, t.toString());
  Object.defineProperty(i, "name", Wn), Object.defineProperty(e, "toString", { ...qn, value: i });
}, "changeToString");
function te(e, t, { ignoreNonConfigurable: n = !1 } = {}) {
  let { name: r } = e;
  for (let i of Reflect.ownKeys(t))
    Mn(e, t, i, n);
  return Dn(e, t), Hn(e, t, r), e;
}
o(te, "mimicFunction");

// node_modules/onetime/index.js
var N = /* @__PURE__ */ new WeakMap(), wt = /* @__PURE__ */ o((e, t = {}) => {
  if (typeof e != "function")
    throw new TypeError("Expected a function");
  let n, r = 0, i = e.displayName || e.name || "<anonymous>", s = /* @__PURE__ */ o(function(...a) {
    if (N.set(s, ++r), r === 1)
      n = e.apply(this, a), e = null;
    else if (t.throw === !0)
      throw new Error(`Function \`${i}\` can only be called once`);
    return n;
  }, "onetime");
  return te(s, e), N.set(s, r), s;
}, "onetime");
wt.callCount = (e) => {
  if (!N.has(e))
    throw new Error(`The given function \`${e.name}\` is not wrapped by the \`onetime\` package`);
  return N.get(e);
};
var Et = wt;

// node_modules/execa/lib/error.js
import nr from "node:process";

// node_modules/human-signals/build/src/main.js
import { constants as Yn } from "node:os";

// node_modules/human-signals/build/src/realtime.js
var Tt = /* @__PURE__ */ o(() => {
  let e = ne - At + 1;
  return Array.from({ length: e }, Kn);
}, "getRealtimeSignals"), Kn = /* @__PURE__ */ o((e, t) => ({
  name: `SIGRT${t + 1}`,
  number: At + t,
  action: "terminate",
  description: "Application-specific signal (realtime)",
  standard: "posix"
}), "getRealtimeSignal"), At = 34, ne = 64;

// node_modules/human-signals/build/src/signals.js
import { constants as Xn } from "node:os";

// node_modules/human-signals/build/src/core.js
var Ct = [
  {
    name: "SIGHUP",
    number: 1,
    action: "terminate",
    description: "Terminal closed",
    standard: "posix"
  },
  {
    name: "SIGINT",
    number: 2,
    action: "terminate",
    description: "User interruption with CTRL-C",
    standard: "ansi"
  },
  {
    name: "SIGQUIT",
    number: 3,
    action: "core",
    description: "User interruption with CTRL-\\",
    standard: "posix"
  },
  {
    name: "SIGILL",
    number: 4,
    action: "core",
    description: "Invalid machine instruction",
    standard: "ansi"
  },
  {
    name: "SIGTRAP",
    number: 5,
    action: "core",
    description: "Debugger breakpoint",
    standard: "posix"
  },
  {
    name: "SIGABRT",
    number: 6,
    action: "core",
    description: "Aborted",
    standard: "ansi"
  },
  {
    name: "SIGIOT",
    number: 6,
    action: "core",
    description: "Aborted",
    standard: "bsd"
  },
  {
    name: "SIGBUS",
    number: 7,
    action: "core",
    description: "Bus error due to misaligned, non-existing address or paging error",
    standard: "bsd"
  },
  {
    name: "SIGEMT",
    number: 7,
    action: "terminate",
    description: "Command should be emulated but is not implemented",
    standard: "other"
  },
  {
    name: "SIGFPE",
    number: 8,
    action: "core",
    description: "Floating point arithmetic error",
    standard: "ansi"
  },
  {
    name: "SIGKILL",
    number: 9,
    action: "terminate",
    description: "Forced termination",
    standard: "posix",
    forced: !0
  },
  {
    name: "SIGUSR1",
    number: 10,
    action: "terminate",
    description: "Application-specific signal",
    standard: "posix"
  },
  {
    name: "SIGSEGV",
    number: 11,
    action: "core",
    description: "Segmentation fault",
    standard: "ansi"
  },
  {
    name: "SIGUSR2",
    number: 12,
    action: "terminate",
    description: "Application-specific signal",
    standard: "posix"
  },
  {
    name: "SIGPIPE",
    number: 13,
    action: "terminate",
    description: "Broken pipe or socket",
    standard: "posix"
  },
  {
    name: "SIGALRM",
    number: 14,
    action: "terminate",
    description: "Timeout or timer",
    standard: "posix"
  },
  {
    name: "SIGTERM",
    number: 15,
    action: "terminate",
    description: "Termination",
    standard: "ansi"
  },
  {
    name: "SIGSTKFLT",
    number: 16,
    action: "terminate",
    description: "Stack is empty or overflowed",
    standard: "other"
  },
  {
    name: "SIGCHLD",
    number: 17,
    action: "ignore",
    description: "Child process terminated, paused or unpaused",
    standard: "posix"
  },
  {
    name: "SIGCLD",
    number: 17,
    action: "ignore",
    description: "Child process terminated, paused or unpaused",
    standard: "other"
  },
  {
    name: "SIGCONT",
    number: 18,
    action: "unpause",
    description: "Unpaused",
    standard: "posix",
    forced: !0
  },
  {
    name: "SIGSTOP",
    number: 19,
    action: "pause",
    description: "Paused",
    standard: "posix",
    forced: !0
  },
  {
    name: "SIGTSTP",
    number: 20,
    action: "pause",
    description: 'Paused using CTRL-Z or "suspend"',
    standard: "posix"
  },
  {
    name: "SIGTTIN",
    number: 21,
    action: "pause",
    description: "Background process cannot read terminal input",
    standard: "posix"
  },
  {
    name: "SIGBREAK",
    number: 21,
    action: "terminate",
    description: "User interruption with CTRL-BREAK",
    standard: "other"
  },
  {
    name: "SIGTTOU",
    number: 22,
    action: "pause",
    description: "Background process cannot write to terminal output",
    standard: "posix"
  },
  {
    name: "SIGURG",
    number: 23,
    action: "ignore",
    description: "Socket received out-of-band data",
    standard: "bsd"
  },
  {
    name: "SIGXCPU",
    number: 24,
    action: "core",
    description: "Process timed out",
    standard: "bsd"
  },
  {
    name: "SIGXFSZ",
    number: 25,
    action: "core",
    description: "File too big",
    standard: "bsd"
  },
  {
    name: "SIGVTALRM",
    number: 26,
    action: "terminate",
    description: "Timeout or timer",
    standard: "bsd"
  },
  {
    name: "SIGPROF",
    number: 27,
    action: "terminate",
    description: "Timeout or timer",
    standard: "bsd"
  },
  {
    name: "SIGWINCH",
    number: 28,
    action: "ignore",
    description: "Terminal window size changed",
    standard: "bsd"
  },
  {
    name: "SIGIO",
    number: 29,
    action: "terminate",
    description: "I/O is available",
    standard: "other"
  },
  {
    name: "SIGPOLL",
    number: 29,
    action: "terminate",
    description: "Watched event",
    standard: "other"
  },
  {
    name: "SIGINFO",
    number: 29,
    action: "ignore",
    description: "Request for process information",
    standard: "other"
  },
  {
    name: "SIGPWR",
    number: 30,
    action: "terminate",
    description: "Device running out of power",
    standard: "systemv"
  },
  {
    name: "SIGSYS",
    number: 31,
    action: "core",
    description: "Invalid system call",
    standard: "other"
  },
  {
    name: "SIGUNUSED",
    number: 31,
    action: "terminate",
    description: "Invalid system call",
    standard: "other"
  }
];

// node_modules/human-signals/build/src/signals.js
var re = /* @__PURE__ */ o(() => {
  let e = Tt();
  return [...Ct, ...e].map(Vn);
}, "getSignals"), Vn = /* @__PURE__ */ o(({
  name: e,
  number: t,
  description: n,
  action: r,
  forced: i = !1,
  standard: s
}) => {
  let {
    signals: { [e]: a }
  } = Xn, c = a !== void 0;
  return { name: e, number: c ? a : t, description: n, supported: c, action: r, forced: i, standard: s };
}, "normalizeSignal");

// node_modules/human-signals/build/src/main.js
var Zn = /* @__PURE__ */ o(() => {
  let e = re();
  return Object.fromEntries(e.map(Qn));
}, "getSignalsByName"), Qn = /* @__PURE__ */ o(({
  name: e,
  number: t,
  description: n,
  supported: r,
  action: i,
  forced: s,
  standard: a
}) => [e, { name: e, number: t, description: n, supported: r, action: i, forced: s, standard: a }], "getSignalByName"), It = Zn(), Jn = /* @__PURE__ */ o(() => {
  let e = re(), t = ne + 1, n = Array.from(
    { length: t },
    (r, i) => er(i, e)
  );
  return Object.assign({}, ...n);
}, "getSignalsByNumber"), er = /* @__PURE__ */ o((e, t) => {
  let n = tr(e, t);
  if (n === void 0)
    return {};
  let { name: r, description: i, supported: s, action: a, forced: c, standard: u } = n;
  return {
    [e]: {
      name: r,
      number: e,
      description: i,
      supported: s,
      action: a,
      forced: c,
      standard: u
    }
  };
}, "getSignalByNumber"), tr = /* @__PURE__ */ o((e, t) => {
  let n = t.find(({ name: r }) => Yn.signals[r] === e);
  return n !== void 0 ? n : t.find((r) => r.number === e);
}, "findSignalByNumber"), ei = Jn();

// node_modules/execa/lib/error.js
var rr = /* @__PURE__ */ o(({ timedOut: e, timeout: t, errorCode: n, signal: r, signalDescription: i, exitCode: s, isCanceled: a }) => e ? `timed out after ${t} milliseconds` : a ? "was canceled" : n !== void 0 ? `failed with ${n}` : r !== void 0 ? `was killed with ${r} (${i})` : s !== void 0 ? `failed with exit code ${s}` : "failed", "getErrorPrefix"), A = /* @__PURE__ */ o(({
  stdout: e,
  stderr: t,
  all: n,
  error: r,
  signal: i,
  exitCode: s,
  command: a,
  escapedCommand: c,
  timedOut: u,
  isCanceled: f,
  killed: l,
  parsed: { options: { timeout: p, cwd: d = nr.cwd() } }
}) => {
  s = s === null ? void 0 : s, i = i === null ? void 0 : i;
  let y = i === void 0 ? void 0 : It[i].description, m = r && r.code, x = `Command ${rr({ timedOut: u, timeout: p, errorCode: m, signal: i, signalDescription: y, exitCode: s, isCanceled: f })}: ${a}`, P = Object.prototype.toString.call(r) === "[object Error]", v = P ? `${x}
${r.message}` : x, O = [v, t, e].filter(Boolean).join(`
`);
  return P ? (r.originalMessage = r.message, r.message = O) : r = new Error(O), r.shortMessage = v, r.command = a, r.escapedCommand = c, r.exitCode = s, r.signal = i, r.signalDescription = y, r.stdout = e, r.stderr = t, r.cwd = d, n !== void 0 && (r.all = n), "bufferedData" in r && delete r.bufferedData, r.failed = !0, r.timedOut = !!u, r.isCanceled = f, r.killed = l && !u, r;
}, "makeError");

// node_modules/execa/lib/stdio.js
var k = ["stdin", "stdout", "stderr"], or = /* @__PURE__ */ o((e) => k.some((t) => e[t] !== void 0), "hasAlias"), Pt = /* @__PURE__ */ o((e) => {
  if (!e)
    return;
  let { stdio: t } = e;
  if (t === void 0)
    return k.map((r) => e[r]);
  if (or(e))
    throw new Error(`It's not possible to provide \`stdio\` in combination with one of ${k.map((r) => `\`${r}\``).join(", ")}`);
  if (typeof t == "string")
    return t;
  if (!Array.isArray(t))
    throw new TypeError(`Expected \`stdio\` to be of type \`string\` or \`Array\`, got \`${typeof t}\``);
  let n = Math.max(t.length, k.length);
  return Array.from({ length: n }, (r, i) => t[i]);
}, "normalizeStdio");

// node_modules/execa/lib/kill.js
import ar from "node:os";

// node_modules/signal-exit/dist/mjs/signals.js
var b = [];
b.push("SIGHUP", "SIGINT", "SIGTERM");
process.platform !== "win32" && b.push(
  "SIGALRM",
  "SIGABRT",
  "SIGVTALRM",
  "SIGXCPU",
  "SIGXFSZ",
  "SIGUSR2",
  "SIGTRAP",
  "SIGSYS",
  "SIGQUIT",
  "SIGIOT"
  // should detect profiler and enable/disable accordingly.
  // see #21
  // 'SIGPROF'
);
process.platform === "linux" && b.push("SIGIO", "SIGPOLL", "SIGPWR", "SIGSTKFLT");

// node_modules/signal-exit/dist/mjs/index.js
var j = /* @__PURE__ */ o((e) => !!e && typeof e == "object" && typeof e.removeListener == "function" && typeof e.emit == "function" && typeof e.reallyExit == "function" && typeof e.listeners == "function" && typeof e.kill == "function" && typeof e.pid == "number" && typeof e.on == "function", "processOk"), oe = Symbol.for("signal-exit emitter"), ie = globalThis, ir = Object.defineProperty.bind(Object), se = class {
  static {
    o(this, "Emitter");
  }
  emitted = {
    afterExit: !1,
    exit: !1
  };
  listeners = {
    afterExit: [],
    exit: []
  };
  count = 0;
  id = Math.random();
  constructor() {
    if (ie[oe])
      return ie[oe];
    ir(ie, oe, {
      value: this,
      writable: !1,
      enumerable: !1,
      configurable: !1
    });
  }
  on(t, n) {
    this.listeners[t].push(n);
  }
  removeListener(t, n) {
    let r = this.listeners[t], i = r.indexOf(n);
    i !== -1 && (i === 0 && r.length === 1 ? r.length = 0 : r.splice(i, 1));
  }
  emit(t, n, r) {
    if (this.emitted[t])
      return !1;
    this.emitted[t] = !0;
    let i = !1;
    for (let s of this.listeners[t])
      i = s(n, r) === !0 || i;
    return t === "exit" && (i = this.emit("afterExit", n, r) || i), i;
  }
}, B = class {
  static {
    o(this, "SignalExitBase");
  }
}, sr = /* @__PURE__ */ o((e) => ({
  onExit(t, n) {
    return e.onExit(t, n);
  },
  load() {
    return e.load();
  },
  unload() {
    return e.unload();
  }
}), "signalExitWrap"), ae = class extends B {
  static {
    o(this, "SignalExitFallback");
  }
  onExit() {
    return () => {
    };
  }
  load() {
  }
  unload() {
  }
}, ce = class extends B {
  static {
    o(this, "SignalExit");
  }
  // "SIGHUP" throws an `ENOSYS` error on Windows,
  // so use a supported signal instead
  /* c8 ignore start */
  #s = ue.platform === "win32" ? "SIGINT" : "SIGHUP";
  /* c8 ignore stop */
  #t = new se();
  #e;
  #o;
  #i;
  #r = {};
  #n = !1;
  constructor(t) {
    super(), this.#e = t, this.#r = {};
    for (let n of b)
      this.#r[n] = () => {
        let r = this.#e.listeners(n), { count: i } = this.#t, s = t;
        if (typeof s.__signal_exit_emitter__ == "object" && typeof s.__signal_exit_emitter__.count == "number" && (i += s.__signal_exit_emitter__.count), r.length === i) {
          this.unload();
          let a = this.#t.emit("exit", null, n), c = n === "SIGHUP" ? this.#s : n;
          a || t.kill(t.pid, c);
        }
      };
    this.#i = t.reallyExit, this.#o = t.emit;
  }
  onExit(t, n) {
    if (!j(this.#e))
      return () => {
      };
    this.#n === !1 && this.load();
    let r = n?.alwaysLast ? "afterExit" : "exit";
    return this.#t.on(r, t), () => {
      this.#t.removeListener(r, t), this.#t.listeners.exit.length === 0 && this.#t.listeners.afterExit.length === 0 && this.unload();
    };
  }
  load() {
    if (!this.#n) {
      this.#n = !0, this.#t.count += 1;
      for (let t of b)
        try {
          let n = this.#r[t];
          n && this.#e.on(t, n);
        } catch {
        }
      this.#e.emit = (t, ...n) => this.#c(t, ...n), this.#e.reallyExit = (t) => this.#a(t);
    }
  }
  unload() {
    this.#n && (this.#n = !1, b.forEach((t) => {
      let n = this.#r[t];
      if (!n)
        throw new Error("Listener not defined for signal: " + t);
      try {
        this.#e.removeListener(t, n);
      } catch {
      }
    }), this.#e.emit = this.#o, this.#e.reallyExit = this.#i, this.#t.count -= 1);
  }
  #a(t) {
    return j(this.#e) ? (this.#e.exitCode = t || 0, this.#t.emit("exit", this.#e.exitCode, null), this.#i.call(this.#e, this.#e.exitCode)) : 0;
  }
  #c(t, ...n) {
    let r = this.#o;
    if (t === "exit" && j(this.#e)) {
      typeof n[0] == "number" && (this.#e.exitCode = n[0]);
      let i = r.call(this.#e, t, ...n);
      return this.#t.emit("exit", this.#e.exitCode, null), i;
    } else
      return r.call(this.#e, t, ...n);
  }
}, ue = globalThis.process, {
  /**
   * Called when the process is exiting, whether via signal, explicit
   * exit, or running out of stuff to do.
   *
   * If the global process object is not suitable for instrumentation,
   * then this will be a no-op.
   *
   * Returns a function that may be used to unload signal-exit.
   */
  onExit: vt,
  /**
   * Load the listeners.  Likely you never need to call this, unless
   * doing a rather deep integration with signal-exit functionality.
   * Mostly exposed for the benefit of testing.
   *
   * @internal
   */
  load: li,
  /**
   * Unload the listeners.  Likely you never need to call this, unless
   * doing a rather deep integration with signal-exit functionality.
   * Mostly exposed for the benefit of testing.
   *
   * @internal
   */
  unload: di
} = sr(j(ue) ? new ce(ue) : new ae());

// node_modules/execa/lib/kill.js
var cr = 1e3 * 5, Ot = /* @__PURE__ */ o((e, t = "SIGTERM", n = {}) => {
  let r = e(t);
  return ur(e, t, n, r), r;
}, "spawnedKill"), ur = /* @__PURE__ */ o((e, t, n, r) => {
  if (!fr(t, n, r))
    return;
  let i = dr(n), s = setTimeout(() => {
    e("SIGKILL");
  }, i);
  s.unref && s.unref();
}, "setKillTimeout"), fr = /* @__PURE__ */ o((e, { forceKillAfterTimeout: t }, n) => lr(e) && t !== !1 && n, "shouldForceKill"), lr = /* @__PURE__ */ o((e) => e === ar.constants.signals.SIGTERM || typeof e == "string" && e.toUpperCase() === "SIGTERM", "isSigterm"), dr = /* @__PURE__ */ o(({ forceKillAfterTimeout: e = !0 }) => {
  if (e === !0)
    return cr;
  if (!Number.isFinite(e) || e < 0)
    throw new TypeError(`Expected the \`forceKillAfterTimeout\` option to be a non-negative integer, got \`${e}\` (${typeof e})`);
  return e;
}, "getForceKillAfterTimeout"), Gt = /* @__PURE__ */ o((e, t) => {
  e.kill() && (t.isCanceled = !0);
}, "spawnedCancel"), pr = /* @__PURE__ */ o((e, t, n) => {
  e.kill(t), n(Object.assign(new Error("Timed out"), { timedOut: !0, signal: t }));
}, "timeoutKill"), Rt = /* @__PURE__ */ o((e, { timeout: t, killSignal: n = "SIGTERM" }, r) => {
  if (t === 0 || t === void 0)
    return r;
  let i, s = new Promise((c, u) => {
    i = setTimeout(() => {
      pr(e, n, u);
    }, t);
  }), a = r.finally(() => {
    clearTimeout(i);
  });
  return Promise.race([s, a]);
}, "setupTimeout"), $t = /* @__PURE__ */ o(({ timeout: e }) => {
  if (e !== void 0 && (!Number.isFinite(e) || e < 0))
    throw new TypeError(`Expected the \`timeout\` option to be a non-negative integer, got \`${e}\` (${typeof e})`);
}, "validateTimeout"), Nt = /* @__PURE__ */ o(async (e, { cleanup: t, detached: n }, r) => {
  if (!t || n)
    return r;
  let i = vt(() => {
    e.kill();
  });
  return r.finally(() => {
    i();
  });
}, "setExitHandler");

// node_modules/execa/lib/pipe.js
import { createWriteStream as mr } from "node:fs";
import { ChildProcess as hr } from "node:child_process";

// node_modules/is-stream/index.js
function L(e) {
  return e !== null && typeof e == "object" && typeof e.pipe == "function";
}
o(L, "isStream");
function fe(e) {
  return L(e) && e.writable !== !1 && typeof e._write == "function" && typeof e._writableState == "object";
}
o(fe, "isWritableStream");

// node_modules/execa/lib/pipe.js
var yr = /* @__PURE__ */ o((e) => e instanceof hr && typeof e.then == "function", "isExecaChildProcess"), le = /* @__PURE__ */ o((e, t, n) => {
  if (typeof n == "string")
    return e[t].pipe(mr(n)), e;
  if (fe(n))
    return e[t].pipe(n), e;
  if (!yr(n))
    throw new TypeError("The second argument must be a string, a stream or an Execa child process.");
  if (!fe(n.stdin))
    throw new TypeError("The target child process's stdin must be available.");
  return e[t].pipe(n.stdin), n;
}, "pipeToTarget"), kt = /* @__PURE__ */ o((e) => {
  e.stdout !== null && (e.pipeStdout = le.bind(void 0, e, "stdout")), e.stderr !== null && (e.pipeStderr = le.bind(void 0, e, "stderr")), e.all !== void 0 && (e.pipeAll = le.bind(void 0, e, "all"));
}, "addPipeMethods");

// node_modules/execa/lib/stream.js
import { createReadStream as jr, readFileSync as Br } from "node:fs";
import { setTimeout as Lr } from "node:timers/promises";

// node_modules/get-stream/source/contents.js
var C = /* @__PURE__ */ o(async (e, { init: t, convertChunk: n, getSize: r, truncateChunk: i, addChunk: s, getFinalChunk: a, finalize: c }, { maxBuffer: u = Number.POSITIVE_INFINITY } = {}) => {
  if (!Sr(e))
    throw new Error("The first argument must be a Readable, a ReadableStream, or an async iterable.");
  let f = t();
  f.length = 0;
  try {
    for await (let l of e) {
      let p = br(l), d = n[p](l, f);
      Lt({ convertedChunk: d, state: f, getSize: r, truncateChunk: i, addChunk: s, maxBuffer: u });
    }
    return gr({ state: f, convertChunk: n, getSize: r, truncateChunk: i, addChunk: s, getFinalChunk: a, maxBuffer: u }), c(f);
  } catch (l) {
    throw l.bufferedData = c(f), l;
  }
}, "getStreamContents"), gr = /* @__PURE__ */ o(({ state: e, getSize: t, truncateChunk: n, addChunk: r, getFinalChunk: i, maxBuffer: s }) => {
  let a = i(e);
  a !== void 0 && Lt({ convertedChunk: a, state: e, getSize: t, truncateChunk: n, addChunk: r, maxBuffer: s });
}, "appendFinalChunk"), Lt = /* @__PURE__ */ o(({ convertedChunk: e, state: t, getSize: n, truncateChunk: r, addChunk: i, maxBuffer: s }) => {
  let a = n(e), c = t.length + a;
  if (c <= s) {
    jt(e, t, i, c);
    return;
  }
  let u = r(e, s - t.length);
  throw u !== void 0 && jt(u, t, i, s), new U();
}, "appendChunk"), jt = /* @__PURE__ */ o((e, t, n, r) => {
  t.contents = n(e, t, r), t.length = r;
}, "addNewChunk"), Sr = /* @__PURE__ */ o((e) => typeof e == "object" && e !== null && typeof e[Symbol.asyncIterator] == "function", "isAsyncIterable"), br = /* @__PURE__ */ o((e) => {
  let t = typeof e;
  if (t === "string")
    return "string";
  if (t !== "object" || e === null)
    return "others";
  if (globalThis.Buffer?.isBuffer(e))
    return "buffer";
  let n = Bt.call(e);
  return n === "[object ArrayBuffer]" ? "arrayBuffer" : n === "[object DataView]" ? "dataView" : Number.isInteger(e.byteLength) && Number.isInteger(e.byteOffset) && Bt.call(e.buffer) === "[object ArrayBuffer]" ? "typedArray" : "others";
}, "getChunkType"), { toString: Bt } = Object.prototype, U = class extends Error {
  static {
    o(this, "MaxBufferError");
  }
  name = "MaxBufferError";
  constructor() {
    super("maxBuffer exceeded");
  }
};

// node_modules/get-stream/source/utils.js
var de = /* @__PURE__ */ o((e) => e, "identity"), pe = /* @__PURE__ */ o(() => {
}, "noop"), me = /* @__PURE__ */ o(({ contents: e }) => e, "getContentsProp"), F = /* @__PURE__ */ o((e) => {
  throw new Error(`Streams in object mode are not supported: ${String(e)}`);
}, "throwObjectStream"), M = /* @__PURE__ */ o((e) => e.length, "getLengthProp");

// node_modules/get-stream/source/array-buffer.js
async function he(e, t) {
  return C(e, vr, t);
}
o(he, "getStreamAsArrayBuffer");
var xr = /* @__PURE__ */ o(() => ({ contents: new ArrayBuffer(0) }), "initArrayBuffer"), wr = /* @__PURE__ */ o((e) => Er.encode(e), "useTextEncoder"), Er = new TextEncoder(), Ut = /* @__PURE__ */ o((e) => new Uint8Array(e), "useUint8Array"), Ft = /* @__PURE__ */ o((e) => new Uint8Array(e.buffer, e.byteOffset, e.byteLength), "useUint8ArrayWithOffset"), Tr = /* @__PURE__ */ o((e, t) => e.slice(0, t), "truncateArrayBufferChunk"), Ar = /* @__PURE__ */ o((e, { contents: t, length: n }, r) => {
  let i = Dt() ? Ir(t, r) : Cr(t, r);
  return new Uint8Array(i).set(e, n), i;
}, "addArrayBufferChunk"), Cr = /* @__PURE__ */ o((e, t) => {
  if (t <= e.byteLength)
    return e;
  let n = new ArrayBuffer(_t(t));
  return new Uint8Array(n).set(new Uint8Array(e), 0), n;
}, "resizeArrayBufferSlow"), Ir = /* @__PURE__ */ o((e, t) => {
  if (t <= e.maxByteLength)
    return e.resize(t), e;
  let n = new ArrayBuffer(t, { maxByteLength: _t(t) });
  return new Uint8Array(n).set(new Uint8Array(e), 0), n;
}, "resizeArrayBuffer"), _t = /* @__PURE__ */ o((e) => Mt ** Math.ceil(Math.log(e) / Math.log(Mt)), "getNewContentsLength"), Mt = 2, Pr = /* @__PURE__ */ o(({ contents: e, length: t }) => Dt() ? e : e.slice(0, t), "finalizeArrayBuffer"), Dt = /* @__PURE__ */ o(() => "resize" in ArrayBuffer.prototype, "hasArrayBufferResize"), vr = {
  init: xr,
  convertChunk: {
    string: wr,
    buffer: Ut,
    arrayBuffer: Ut,
    dataView: Ft,
    typedArray: Ft,
    others: F
  },
  getSize: M,
  truncateChunk: Tr,
  addChunk: Ar,
  getFinalChunk: pe,
  finalize: Pr
};

// node_modules/get-stream/source/buffer.js
async function _(e, t) {
  if (!("Buffer" in globalThis))
    throw new Error("getStreamAsBuffer() is only supported in Node.js");
  try {
    return zt(await he(e, t));
  } catch (n) {
    throw n.bufferedData !== void 0 && (n.bufferedData = zt(n.bufferedData)), n;
  }
}
o(_, "getStreamAsBuffer");
var zt = /* @__PURE__ */ o((e) => globalThis.Buffer.from(e), "arrayBufferToNodeBuffer");

// node_modules/get-stream/source/string.js
async function ye(e, t) {
  return C(e, Nr, t);
}
o(ye, "getStreamAsString");
var Or = /* @__PURE__ */ o(() => ({ contents: "", textDecoder: new TextDecoder() }), "initString"), D = /* @__PURE__ */ o((e, { textDecoder: t }) => t.decode(e, { stream: !0 }), "useTextDecoder"), Gr = /* @__PURE__ */ o((e, { contents: t }) => t + e, "addStringChunk"), Rr = /* @__PURE__ */ o((e, t) => e.slice(0, t), "truncateStringChunk"), $r = /* @__PURE__ */ o(({ textDecoder: e }) => {
  let t = e.decode();
  return t === "" ? void 0 : t;
}, "getFinalStringChunk"), Nr = {
  init: Or,
  convertChunk: {
    string: de,
    buffer: D,
    arrayBuffer: D,
    dataView: D,
    typedArray: D,
    others: F
  },
  getSize: M,
  truncateChunk: Rr,
  addChunk: Gr,
  getFinalChunk: $r,
  finalize: me
};

// node_modules/execa/lib/stream.js
var Ht = Ge(Wt(), 1);
var Kt = /* @__PURE__ */ o((e) => {
  if (e !== void 0)
    throw new TypeError("The `input` and `inputFile` options cannot be both set.");
}, "validateInputOptions"), Ur = /* @__PURE__ */ o(({ input: e, inputFile: t }) => typeof t != "string" ? e : (Kt(e), Br(t)), "getInputSync"), Xt = /* @__PURE__ */ o((e) => {
  let t = Ur(e);
  if (L(t))
    throw new TypeError("The `input` option cannot be a stream in sync mode");
  return t;
}, "handleInputSync"), Fr = /* @__PURE__ */ o(({ input: e, inputFile: t }) => typeof t != "string" ? e : (Kt(e), jr(t)), "getInput"), Vt = /* @__PURE__ */ o((e, t) => {
  let n = Fr(t);
  n !== void 0 && (L(n) ? n.pipe(e.stdin) : e.stdin.end(n));
}, "handleInput"), Yt = /* @__PURE__ */ o((e, { all: t }) => {
  if (!t || !e.stdout && !e.stderr)
    return;
  let n = (0, Ht.default)();
  return e.stdout && n.add(e.stdout), e.stderr && n.add(e.stderr), n;
}, "makeAllStream"), ge = /* @__PURE__ */ o(async (e, t) => {
  if (!(!e || t === void 0)) {
    await Lr(0), e.destroy();
    try {
      return await t;
    } catch (n) {
      return n.bufferedData;
    }
  }
}, "getBufferedData"), Se = /* @__PURE__ */ o((e, { encoding: t, buffer: n, maxBuffer: r }) => {
  if (!(!e || !n))
    return t === "utf8" || t === "utf-8" ? ye(e, { maxBuffer: r }) : t === null || t === "buffer" ? _(e, { maxBuffer: r }) : Mr(e, r, t);
}, "getStreamPromise"), Mr = /* @__PURE__ */ o(async (e, t, n) => (await _(e, { maxBuffer: t })).toString(n), "applyEncoding"), Zt = /* @__PURE__ */ o(async ({ stdout: e, stderr: t, all: n }, { encoding: r, buffer: i, maxBuffer: s }, a) => {
  let c = Se(e, { encoding: r, buffer: i, maxBuffer: s }), u = Se(t, { encoding: r, buffer: i, maxBuffer: s }), f = Se(n, { encoding: r, buffer: i, maxBuffer: s * 2 });
  try {
    return await Promise.all([a, c, u, f]);
  } catch (l) {
    return Promise.all([
      { error: l, signal: l.signal, timedOut: l.timedOut },
      ge(e, c),
      ge(t, u),
      ge(n, f)
    ]);
  }
}, "getSpawnedResult");

// node_modules/execa/lib/promise.js
var _r = (async () => {
})().constructor.prototype, Dr = ["then", "catch", "finally"].map((e) => [
  e,
  Reflect.getOwnPropertyDescriptor(_r, e)
]), be = /* @__PURE__ */ o((e, t) => {
  for (let [n, r] of Dr) {
    let i = typeof t == "function" ? (...s) => Reflect.apply(r.value, t(), s) : r.value.bind(t);
    Reflect.defineProperty(e, n, { ...r, value: i });
  }
}, "mergePromise"), Qt = /* @__PURE__ */ o((e) => new Promise((t, n) => {
  e.on("exit", (r, i) => {
    t({ exitCode: r, signal: i });
  }), e.on("error", (r) => {
    n(r);
  }), e.stdin && e.stdin.on("error", (r) => {
    n(r);
  });
}), "getSpawnedPromise");

// node_modules/execa/lib/command.js
import { Buffer as zr } from "node:buffer";
import { ChildProcess as qr } from "node:child_process";
var tn = /* @__PURE__ */ o((e, t = []) => Array.isArray(t) ? [e, ...t] : [e], "normalizeArgs"), Wr = /^[\w.-]+$/, Hr = /* @__PURE__ */ o((e) => typeof e != "string" || Wr.test(e) ? e : `"${e.replaceAll('"', '\\"')}"`, "escapeArg"), xe = /* @__PURE__ */ o((e, t) => tn(e, t).join(" "), "joinCommand"), we = /* @__PURE__ */ o((e, t) => tn(e, t).map((n) => Hr(n)).join(" "), "getEscapedCommand"), nn = / +/g, Ee = /* @__PURE__ */ o((e) => {
  let t = [];
  for (let n of e.trim().split(nn)) {
    let r = t.at(-1);
    r && r.endsWith("\\") ? t[t.length - 1] = `${r.slice(0, -1)} ${n}` : t.push(n);
  }
  return t;
}, "parseCommand"), Jt = /* @__PURE__ */ o((e) => {
  let t = typeof e;
  if (t === "string")
    return e;
  if (t === "number")
    return String(e);
  if (t === "object" && e !== null && !(e instanceof qr) && "stdout" in e) {
    let n = typeof e.stdout;
    if (n === "string")
      return e.stdout;
    if (zr.isBuffer(e.stdout))
      return e.stdout.toString();
    throw new TypeError(`Unexpected "${n}" stdout in template expression`);
  }
  throw new TypeError(`Unexpected "${t}" in template expression`);
}, "parseExpression"), en = /* @__PURE__ */ o((e, t, n) => n || e.length === 0 || t.length === 0 ? [...e, ...t] : [
  ...e.slice(0, -1),
  `${e.at(-1)}${t[0]}`,
  ...t.slice(1)
], "concatTokens"), Kr = /* @__PURE__ */ o(({ templates: e, expressions: t, tokens: n, index: r, template: i }) => {
  let s = i ?? e.raw[r], a = s.split(nn).filter(Boolean), c = en(
    n,
    a,
    s.startsWith(" ")
  );
  if (r === t.length)
    return c;
  let u = t[r], f = Array.isArray(u) ? u.map((l) => Jt(l)) : [Jt(u)];
  return en(
    c,
    f,
    s.endsWith(" ")
  );
}, "parseTemplate"), Te = /* @__PURE__ */ o((e, t) => {
  let n = [];
  for (let [r, i] of e.entries())
    n = Kr({ templates: e, expressions: t, tokens: n, index: r, template: i });
  return n;
}, "parseTemplates");

// node_modules/execa/lib/verbose.js
import { debuglog as Xr } from "node:util";
import Vr from "node:process";
var rn = Xr("execa").enabled, z = /* @__PURE__ */ o((e, t) => String(e).padStart(t, "0"), "padField"), Yr = /* @__PURE__ */ o(() => {
  let e = /* @__PURE__ */ new Date();
  return `${z(e.getHours(), 2)}:${z(e.getMinutes(), 2)}:${z(e.getSeconds(), 2)}.${z(e.getMilliseconds(), 3)}`;
}, "getTimestamp"), Ae = /* @__PURE__ */ o((e, { verbose: t }) => {
  t && Vr.stderr.write(`[${Yr()}] ${e}
`);
}, "logCommand");

// node_modules/execa/index.js
var Jr = 1e3 * 1e3 * 100, eo = /* @__PURE__ */ o(({ env: e, extendEnv: t, preferLocal: n, localDir: r, execPath: i }) => {
  let s = t ? { ...q.env, ...e } : e;
  return n ? xt({ env: s, cwd: r, execPath: i }) : s;
}, "getEnv"), an = /* @__PURE__ */ o((e, t, n = {}) => {
  let r = sn.default._parse(e, t, n);
  return e = r.command, t = r.args, n = r.options, n = {
    maxBuffer: Jr,
    buffer: !0,
    stripFinalNewline: !0,
    extendEnv: !0,
    preferLocal: !1,
    localDir: n.cwd || q.cwd(),
    execPath: q.execPath,
    encoding: "utf8",
    reject: !0,
    cleanup: !0,
    all: !1,
    windowsHide: !0,
    verbose: rn,
    ...n
  }, n.env = eo(n), n.stdio = Pt(n), q.platform === "win32" && Qr.basename(e, ".exe") === "cmd" && t.unshift("/q"), { file: e, args: t, options: n, parsed: r };
}, "handleArguments"), I = /* @__PURE__ */ o((e, t, n) => typeof t != "string" && !Zr.isBuffer(t) ? n === void 0 ? void 0 : "" : e.stripFinalNewline ? ee(t) : t, "handleOutput");
function cn(e, t, n) {
  let r = an(e, t, n), i = xe(e, t), s = we(e, t);
  Ae(s, r.options), $t(r.options);
  let a;
  try {
    a = Ce.spawn(r.file, r.args, r.options);
  } catch (y) {
    let m = new Ce.ChildProcess(), g = Promise.reject(A({
      error: y,
      stdout: "",
      stderr: "",
      all: "",
      command: i,
      escapedCommand: s,
      parsed: r,
      timedOut: !1,
      isCanceled: !1,
      killed: !1
    }));
    return be(m, g), m;
  }
  let c = Qt(a), u = Rt(a, r.options, c), f = Nt(a, r.options, u), l = { isCanceled: !1 };
  a.kill = Ot.bind(null, a.kill.bind(a)), a.cancel = Gt.bind(null, a, l);
  let d = Et(/* @__PURE__ */ o(async () => {
    let [{ error: y, exitCode: m, signal: g, timedOut: x }, P, v, O] = await Zt(a, r.options, f), Ie = I(r.options, P), Pe = I(r.options, v), ve = I(r.options, O);
    if (y || m !== 0 || g !== null) {
      let Oe = A({
        error: y,
        exitCode: m,
        signal: g,
        stdout: Ie,
        stderr: Pe,
        all: ve,
        command: i,
        escapedCommand: s,
        parsed: r,
        timedOut: x,
        isCanceled: l.isCanceled || (r.options.signal ? r.options.signal.aborted : !1),
        killed: a.killed
      });
      if (!r.options.reject)
        return Oe;
      throw Oe;
    }
    return {
      command: i,
      escapedCommand: s,
      exitCode: 0,
      stdout: Ie,
      stderr: Pe,
      all: ve,
      failed: !1,
      timedOut: !1,
      isCanceled: !1,
      killed: !1
    };
  }, "handlePromise"));
  return Vt(a, r.options), a.all = Yt(a, r.options), kt(a), be(a, d), a;
}
o(cn, "execa");
function un(e, t, n) {
  let r = an(e, t, n), i = xe(e, t), s = we(e, t);
  Ae(s, r.options);
  let a = Xt(r.options), c;
  try {
    c = Ce.spawnSync(r.file, r.args, { ...r.options, input: a });
  } catch (l) {
    throw A({
      error: l,
      stdout: "",
      stderr: "",
      all: "",
      command: i,
      escapedCommand: s,
      parsed: r,
      timedOut: !1,
      isCanceled: !1,
      killed: !1
    });
  }
  let u = I(r.options, c.stdout, c.error), f = I(r.options, c.stderr, c.error);
  if (c.error || c.status !== 0 || c.signal !== null) {
    let l = A({
      stdout: u,
      stderr: f,
      error: c.error,
      signal: c.signal,
      exitCode: c.status,
      command: i,
      escapedCommand: s,
      parsed: r,
      timedOut: c.error && c.error.code === "ETIMEDOUT",
      isCanceled: !1,
      killed: c.signal !== null
    });
    if (!r.options.reject)
      return l;
    throw l;
  }
  return {
    command: i,
    escapedCommand: s,
    exitCode: 0,
    stdout: u,
    stderr: f,
    failed: !1,
    timedOut: !1,
    isCanceled: !1,
    killed: !1
  };
}
o(un, "execaSync");
var to = /* @__PURE__ */ o(({ input: e, inputFile: t, stdio: n }) => e === void 0 && t === void 0 && n === void 0 ? { stdin: "inherit" } : {}, "normalizeScriptStdin"), on = /* @__PURE__ */ o((e = {}) => ({
  preferLocal: !0,
  ...to(e),
  ...e
}), "normalizeScriptOptions");
function fn(e) {
  function t(n, ...r) {
    if (!Array.isArray(n))
      return fn({ ...e, ...n });
    let [i, ...s] = Te(n, r);
    return cn(i, s, on(e));
  }
  return o(t, "$"), t.sync = (n, ...r) => {
    if (!Array.isArray(n))
      throw new TypeError("Please use $(options).sync`command` instead of $.sync(options)`command`.");
    let [i, ...s] = Te(n, r);
    return un(i, s, on(e));
  }, t;
}
o(fn, "create$");
var $s = fn();
function Ns(e, t) {
  let [n, ...r] = Ee(e);
  return cn(n, r, t);
}
o(Ns, "execaCommand");
function ks(e, t) {
  let [n, ...r] = Ee(e);
  return un(n, r, t);
}
o(ks, "execaCommandSync");

export {
  St as a,
  cn as b,
  un as c,
  Ns as d,
  ks as e
};
