@hot-updater/cli-tools 0.26.1 → 0.26.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 +56 -56
- package/package.json +4 -4
package/dist/index.js
CHANGED
|
@@ -8,7 +8,7 @@ import fs$1 from "fs/promises";
|
|
|
8
8
|
import assert from "assert";
|
|
9
9
|
import crypto from "crypto";
|
|
10
10
|
import { Buffer as Buffer$1 } from "buffer";
|
|
11
|
-
import
|
|
11
|
+
import N, { execArgv, execPath, hrtime, platform, stdin, stdout } from "node:process";
|
|
12
12
|
import * as k from "node:readline";
|
|
13
13
|
import ot from "node:readline";
|
|
14
14
|
import tty, { ReadStream } from "node:tty";
|
|
@@ -11343,9 +11343,9 @@ var require_lockfile$1 = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/
|
|
|
11343
11343
|
}
|
|
11344
11344
|
exports$1.MessageError = MessageError;
|
|
11345
11345
|
class ProcessSpawnError extends MessageError {
|
|
11346
|
-
constructor(msg$3, code$1, process$
|
|
11346
|
+
constructor(msg$3, code$1, process$2) {
|
|
11347
11347
|
super(msg$3, code$1);
|
|
11348
|
-
this.process = process$
|
|
11348
|
+
this.process = process$2;
|
|
11349
11349
|
}
|
|
11350
11350
|
}
|
|
11351
11351
|
exports$1.ProcessSpawnError = ProcessSpawnError;
|
|
@@ -14907,7 +14907,7 @@ var require_lockfile$1 = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/
|
|
|
14907
14907
|
var html = __webpack_require__(102);
|
|
14908
14908
|
var cel = __webpack_require__(68);
|
|
14909
14909
|
var global$2 = __webpack_require__(11);
|
|
14910
|
-
var process$
|
|
14910
|
+
var process$2 = global$2.process;
|
|
14911
14911
|
var setTask = global$2.setImmediate;
|
|
14912
14912
|
var clearTask = global$2.clearImmediate;
|
|
14913
14913
|
var MessageChannel$1 = global$2.MessageChannel;
|
|
@@ -14941,8 +14941,8 @@ var require_lockfile$1 = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/
|
|
|
14941
14941
|
clearTask = function clearImmediate(id) {
|
|
14942
14942
|
delete queue$1[id];
|
|
14943
14943
|
};
|
|
14944
|
-
if (__webpack_require__(47)(process$
|
|
14945
|
-
process$
|
|
14944
|
+
if (__webpack_require__(47)(process$2) == "process") defer$1 = function(id) {
|
|
14945
|
+
process$2.nextTick(ctx(run, id, 1));
|
|
14946
14946
|
};
|
|
14947
14947
|
else if (Dispatch && Dispatch.now) defer$1 = function(id) {
|
|
14948
14948
|
Dispatch.now(ctx(run, id, 1));
|
|
@@ -16009,7 +16009,7 @@ var require_lockfile$1 = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/
|
|
|
16009
16009
|
}
|
|
16010
16010
|
var pre = m.pre;
|
|
16011
16011
|
var post = m.post.length ? expand$2(m.post, false) : [""];
|
|
16012
|
-
var N$
|
|
16012
|
+
var N$2;
|
|
16013
16013
|
if (isSequence) {
|
|
16014
16014
|
var x$2 = numeric$2(n$1[0]);
|
|
16015
16015
|
var y$1 = numeric$2(n$1[1]);
|
|
@@ -16021,7 +16021,7 @@ var require_lockfile$1 = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/
|
|
|
16021
16021
|
test = gte;
|
|
16022
16022
|
}
|
|
16023
16023
|
var pad$1 = n$1.some(isPadded);
|
|
16024
|
-
N$
|
|
16024
|
+
N$2 = [];
|
|
16025
16025
|
for (var i$4 = x$2; test(i$4, y$1); i$4 += incr) {
|
|
16026
16026
|
var c$2;
|
|
16027
16027
|
if (isAlphaSequence) {
|
|
@@ -16038,13 +16038,13 @@ var require_lockfile$1 = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/
|
|
|
16038
16038
|
}
|
|
16039
16039
|
}
|
|
16040
16040
|
}
|
|
16041
|
-
N$
|
|
16041
|
+
N$2.push(c$2);
|
|
16042
16042
|
}
|
|
16043
|
-
} else N$
|
|
16043
|
+
} else N$2 = concatMap(n$1, function(el) {
|
|
16044
16044
|
return expand$2(el, false);
|
|
16045
16045
|
});
|
|
16046
|
-
for (var j$1 = 0; j$1 < N$
|
|
16047
|
-
var expansion = pre + N$
|
|
16046
|
+
for (var j$1 = 0; j$1 < N$2.length; j$1++) for (var k$1 = 0; k$1 < post.length; k$1++) {
|
|
16047
|
+
var expansion = pre + N$2[j$1] + post[k$1];
|
|
16048
16048
|
if (!isTop || isSequence || expansion) expansions.push(expansion);
|
|
16049
16049
|
}
|
|
16050
16050
|
return expansions;
|
|
@@ -16263,14 +16263,14 @@ var require_lockfile$1 = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/
|
|
|
16263
16263
|
var global$2 = __webpack_require__(11);
|
|
16264
16264
|
var macrotask = __webpack_require__(109).set;
|
|
16265
16265
|
var Observer = global$2.MutationObserver || global$2.WebKitMutationObserver;
|
|
16266
|
-
var process$
|
|
16266
|
+
var process$2 = global$2.process;
|
|
16267
16267
|
var Promise$2 = global$2.Promise;
|
|
16268
|
-
var isNode = __webpack_require__(47)(process$
|
|
16268
|
+
var isNode = __webpack_require__(47)(process$2) == "process";
|
|
16269
16269
|
module$1.exports = function() {
|
|
16270
16270
|
var head, last, notify;
|
|
16271
16271
|
var flush = function() {
|
|
16272
16272
|
var parent, fn;
|
|
16273
|
-
if (isNode && (parent = process$
|
|
16273
|
+
if (isNode && (parent = process$2.domain)) parent.exit();
|
|
16274
16274
|
while (head) {
|
|
16275
16275
|
fn = head.fn;
|
|
16276
16276
|
head = head.next;
|
|
@@ -16286,7 +16286,7 @@ var require_lockfile$1 = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/
|
|
|
16286
16286
|
if (parent) parent.enter();
|
|
16287
16287
|
};
|
|
16288
16288
|
if (isNode) notify = function() {
|
|
16289
|
-
process$
|
|
16289
|
+
process$2.nextTick(flush);
|
|
16290
16290
|
};
|
|
16291
16291
|
else if (Observer && !(global$2.navigator && global$2.navigator.standalone)) {
|
|
16292
16292
|
var toggle = true;
|
|
@@ -16513,11 +16513,11 @@ var require_lockfile$1 = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/
|
|
|
16513
16513
|
var promiseResolve = __webpack_require__(105);
|
|
16514
16514
|
var PROMISE = "Promise";
|
|
16515
16515
|
var TypeError$1 = global$2.TypeError;
|
|
16516
|
-
var process$
|
|
16517
|
-
var versions = process$
|
|
16516
|
+
var process$2 = global$2.process;
|
|
16517
|
+
var versions = process$2 && process$2.versions;
|
|
16518
16518
|
var v8 = versions && versions.v8 || "";
|
|
16519
16519
|
var $Promise = global$2[PROMISE];
|
|
16520
|
-
var isNode = classof(process$
|
|
16520
|
+
var isNode = classof(process$2) == "process";
|
|
16521
16521
|
var empty = function() {};
|
|
16522
16522
|
var Internal, newGenericPromiseCapability, OwnPromiseCapability, Wrapper;
|
|
16523
16523
|
var newPromiseCapability = newGenericPromiseCapability = newPromiseCapabilityModule.f;
|
|
@@ -16585,7 +16585,7 @@ var require_lockfile$1 = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/
|
|
|
16585
16585
|
var result, handler, console$1;
|
|
16586
16586
|
if (unhandled) {
|
|
16587
16587
|
result = perform(function() {
|
|
16588
|
-
if (isNode) process$
|
|
16588
|
+
if (isNode) process$2.emit("unhandledRejection", value$1, promise$1);
|
|
16589
16589
|
else if (handler = global$2.onunhandledrejection) handler({
|
|
16590
16590
|
promise: promise$1,
|
|
16591
16591
|
reason: value$1
|
|
@@ -16604,7 +16604,7 @@ var require_lockfile$1 = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/
|
|
|
16604
16604
|
var onHandleUnhandled = function(promise$1) {
|
|
16605
16605
|
task.call(global$2, function() {
|
|
16606
16606
|
var handler;
|
|
16607
|
-
if (isNode) process$
|
|
16607
|
+
if (isNode) process$2.emit("rejectionHandled", promise$1);
|
|
16608
16608
|
else if (handler = global$2.onrejectionhandled) handler({
|
|
16609
16609
|
promise: promise$1,
|
|
16610
16610
|
reason: promise$1._v
|
|
@@ -16677,7 +16677,7 @@ var require_lockfile$1 = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/
|
|
|
16677
16677
|
var reaction = newPromiseCapability(speciesConstructor(this, $Promise));
|
|
16678
16678
|
reaction.ok = typeof onFulfilled == "function" ? onFulfilled : true;
|
|
16679
16679
|
reaction.fail = typeof onRejected == "function" && onRejected;
|
|
16680
|
-
reaction.domain = isNode ? process$
|
|
16680
|
+
reaction.domain = isNode ? process$2.domain : void 0;
|
|
16681
16681
|
this._c.push(reaction);
|
|
16682
16682
|
if (this._a) this._a.push(reaction);
|
|
16683
16683
|
if (this._s) notify(this, false);
|
|
@@ -19399,7 +19399,7 @@ var dist_exports = /* @__PURE__ */ __export({
|
|
|
19399
19399
|
var import_picocolors$2 = /* @__PURE__ */ __toESM(require_picocolors(), 1);
|
|
19400
19400
|
var import_src = /* @__PURE__ */ __toESM(require_src(), 1);
|
|
19401
19401
|
function me() {
|
|
19402
|
-
return
|
|
19402
|
+
return N.platform !== "win32" ? N.env.TERM !== "linux" : !!N.env.CI || !!N.env.WT_SESSION || !!N.env.TERMINUS_SUBLIME || N.env.ConEmuTask === "{cmd::Cmder}" || N.env.TERM_PROGRAM === "Terminus-Sublime" || N.env.TERM_PROGRAM === "vscode" || N.env.TERM === "xterm-256color" || N.env.TERM === "alacritty" || N.env.TERMINAL_EMULATOR === "JetBrains-JediTerm";
|
|
19403
19403
|
}
|
|
19404
19404
|
const et = me(), ct = () => process.env.CI === "true", Mt$1 = (t$4) => t$4.isTTY === !0, C = (t$4, r) => et ? t$4 : r, Rt = C("◆", "*"), dt = C("■", "x"), $t$1 = C("▲", "x"), V = C("◇", "o"), ht = C("┌", "T"), d = C("│", "|"), x = C("└", "—"), Ot = C("┐", "T"), Pt = C("┘", "—"), Q = C("●", ">"), H = C("○", " "), st = C("◻", "[•]"), U = C("◼", "[+]"), q$1 = C("◻", "[ ]"), Nt = C("▪", "•"), rt$1 = C("─", "-"), mt = C("╮", "+"), Wt$1 = C("├", "+"), pt = C("╯", "+"), gt = C("╰", "+"), Lt$1 = C("╭", "+"), ft = C("●", "•"), Ft = C("◆", "*"), yt$1 = C("▲", "!"), Et = C("■", "x"), W = (t$4) => {
|
|
19405
19405
|
switch (t$4) {
|
|
@@ -20039,7 +20039,7 @@ ${import_picocolors$2.default.cyan(x)}
|
|
|
20039
20039
|
`), o$1 = a$1.reduce((n$1, c$2) => Math.max(M(c$2), n$1), 0);
|
|
20040
20040
|
return J(t$4, r - (a$1.map(s).reduce((n$1, c$2) => Math.max(M(c$2), n$1), 0) - o$1), i$4);
|
|
20041
20041
|
}, Ve = (t$4 = "", r = "", s) => {
|
|
20042
|
-
const i$4 = s?.output ??
|
|
20042
|
+
const i$4 = s?.output ?? N.stdout, a$1 = s?.withGuide ?? _.withGuide, o$1 = s?.format ?? Ge, u$1 = [
|
|
20043
20043
|
"",
|
|
20044
20044
|
...ke(t$4, rt(i$4) - 6, o$1).split(`
|
|
20045
20045
|
`).map(o$1),
|
|
@@ -20983,13 +20983,13 @@ var ansi_styles_default$1 = ansiStyles$1;
|
|
|
20983
20983
|
|
|
20984
20984
|
//#endregion
|
|
20985
20985
|
//#region ../../node_modules/.pnpm/chalk@5.4.1/node_modules/chalk/source/vendor/supports-color/index.js
|
|
20986
|
-
function hasFlag(flag, argv$1 = globalThis.Deno ? globalThis.Deno.args :
|
|
20986
|
+
function hasFlag(flag, argv$1 = globalThis.Deno ? globalThis.Deno.args : N.argv) {
|
|
20987
20987
|
const prefix = flag.startsWith("-") ? "" : flag.length === 1 ? "-" : "--";
|
|
20988
20988
|
const position = argv$1.indexOf(prefix + flag);
|
|
20989
20989
|
const terminatorPosition = argv$1.indexOf("--");
|
|
20990
20990
|
return position !== -1 && (terminatorPosition === -1 || position < terminatorPosition);
|
|
20991
20991
|
}
|
|
20992
|
-
const { env: env$1 } =
|
|
20992
|
+
const { env: env$1 } = N;
|
|
20993
20993
|
let flagForceColor;
|
|
20994
20994
|
if (hasFlag("no-color") || hasFlag("no-colors") || hasFlag("color=false") || hasFlag("color=never")) flagForceColor = 0;
|
|
20995
20995
|
else if (hasFlag("color") || hasFlag("colors") || hasFlag("color=true") || hasFlag("color=always")) flagForceColor = 1;
|
|
@@ -21022,7 +21022,7 @@ function _supportsColor(haveStream, { streamIsTTY, sniffFlags = true } = {}) {
|
|
|
21022
21022
|
if (haveStream && !streamIsTTY && forceColor === void 0) return 0;
|
|
21023
21023
|
const min = forceColor || 0;
|
|
21024
21024
|
if (env$1.TERM === "dumb") return min;
|
|
21025
|
-
if (
|
|
21025
|
+
if (N.platform === "win32") {
|
|
21026
21026
|
const osRelease = os.release().split(".");
|
|
21027
21027
|
if (Number(osRelease[0]) >= 10 && Number(osRelease[2]) >= 10586) return Number(osRelease[2]) >= 14931 ? 3 : 2;
|
|
21028
21028
|
return 1;
|
|
@@ -21804,7 +21804,7 @@ const NEWLINE$2 = "\n";
|
|
|
21804
21804
|
const PAD = " ";
|
|
21805
21805
|
const NONE = "none";
|
|
21806
21806
|
const terminalColumns = () => {
|
|
21807
|
-
const { env: env$3, stdout: stdout$1, stderr } =
|
|
21807
|
+
const { env: env$3, stdout: stdout$1, stderr } = N;
|
|
21808
21808
|
if (stdout$1?.columns) return stdout$1.columns;
|
|
21809
21809
|
if (stderr?.columns) return stderr.columns;
|
|
21810
21810
|
if (env$3.COLUMNS) return Number.parseInt(env$3.COLUMNS, 10);
|
|
@@ -21947,8 +21947,8 @@ const boxContent = (content, contentWidth, options) => {
|
|
|
21947
21947
|
return result;
|
|
21948
21948
|
};
|
|
21949
21949
|
const sanitizeOptions = (options) => {
|
|
21950
|
-
if (options.fullscreen &&
|
|
21951
|
-
let newDimensions = [
|
|
21950
|
+
if (options.fullscreen && N?.stdout) {
|
|
21951
|
+
let newDimensions = [N.stdout.columns, N.stdout.rows];
|
|
21952
21952
|
if (typeof options.fullscreen === "function") newDimensions = options.fullscreen(...newDimensions);
|
|
21953
21953
|
options.width ||= newDimensions[0];
|
|
21954
21954
|
options.height ||= newDimensions[1];
|
|
@@ -36273,9 +36273,9 @@ const getSubprocessResult = ({ stdout: stdout$1 }) => {
|
|
|
36273
36273
|
//#region ../../node_modules/.pnpm/execa@9.5.2/node_modules/execa/lib/utils/standard-stream.js
|
|
36274
36274
|
const isStandardStream = (stream$1) => STANDARD_STREAMS.includes(stream$1);
|
|
36275
36275
|
const STANDARD_STREAMS = [
|
|
36276
|
-
|
|
36277
|
-
|
|
36278
|
-
|
|
36276
|
+
N.stdin,
|
|
36277
|
+
N.stdout,
|
|
36278
|
+
N.stderr
|
|
36279
36279
|
];
|
|
36280
36280
|
const STANDARD_STREAMS_ALIASES = [
|
|
36281
36281
|
"stdin",
|
|
@@ -36400,9 +36400,9 @@ const NO_ESCAPE_REGEXP = /^[\w./-]+$/;
|
|
|
36400
36400
|
//#endregion
|
|
36401
36401
|
//#region ../../node_modules/.pnpm/is-unicode-supported@2.1.0/node_modules/is-unicode-supported/index.js
|
|
36402
36402
|
function isUnicodeSupported() {
|
|
36403
|
-
const { env: env$3 } =
|
|
36403
|
+
const { env: env$3 } = N;
|
|
36404
36404
|
const { TERM, TERM_PROGRAM } = env$3;
|
|
36405
|
-
if (
|
|
36405
|
+
if (N.platform !== "win32") return TERM !== "linux";
|
|
36406
36406
|
return Boolean(env$3.WT_SESSION) || Boolean(env$3.TERMINUS_SUBLIME) || env$3.ConEmuTask === "{cmd::Cmder}" || TERM_PROGRAM === "Terminus-Sublime" || TERM_PROGRAM === "vscode" || TERM === "xterm-256color" || TERM === "alacritty" || TERM === "rxvt-unicode" || TERM === "rxvt-unicode-256color" || env$3.TERMINAL_EMULATOR === "JetBrains-JediTerm";
|
|
36407
36407
|
}
|
|
36408
36408
|
|
|
@@ -37328,7 +37328,7 @@ const TEN_MEGABYTES_IN_BYTES = 10 * 1024 * 1024;
|
|
|
37328
37328
|
|
|
37329
37329
|
//#endregion
|
|
37330
37330
|
//#region ../../node_modules/.pnpm/npm-run-path@6.0.0/node_modules/npm-run-path/index.js
|
|
37331
|
-
const npmRunPath = ({ cwd =
|
|
37331
|
+
const npmRunPath = ({ cwd = N.cwd(), path: pathOption = N.env[pathKey()], preferLocal = true, execPath: execPath$1 = N.execPath, addExecPath = true } = {}) => {
|
|
37332
37332
|
const cwdPath = path$1.resolve(toPath$2(cwd));
|
|
37333
37333
|
const result = [];
|
|
37334
37334
|
const pathParts = pathOption.split(path$1.delimiter);
|
|
@@ -37346,7 +37346,7 @@ const applyExecPath = (result, pathParts, execPath$1, cwdPath) => {
|
|
|
37346
37346
|
const pathPart = path$1.resolve(cwdPath, toPath$2(execPath$1), "..");
|
|
37347
37347
|
if (!pathParts.includes(pathPart)) result.push(pathPart);
|
|
37348
37348
|
};
|
|
37349
|
-
const npmRunPathEnv = ({ env: env$3 =
|
|
37349
|
+
const npmRunPathEnv = ({ env: env$3 = N.env,...options } = {}) => {
|
|
37350
37350
|
env$3 = { ...env$3 };
|
|
37351
37351
|
const pathName = pathKey({ env: env$3 });
|
|
37352
37352
|
options.path = env$3[pathName];
|
|
@@ -38481,7 +38481,7 @@ const normalizeCwd = (cwd = getDefaultCwd()) => {
|
|
|
38481
38481
|
};
|
|
38482
38482
|
const getDefaultCwd = () => {
|
|
38483
38483
|
try {
|
|
38484
|
-
return
|
|
38484
|
+
return N.cwd();
|
|
38485
38485
|
} catch (error) {
|
|
38486
38486
|
error.message = `The current directory does not exist.\n${error.message}`;
|
|
38487
38487
|
throw error;
|
|
@@ -38516,7 +38516,7 @@ const normalizeOptions = (filePath, rawArguments, rawOptions) => {
|
|
|
38516
38516
|
options.killSignal = normalizeKillSignal(options.killSignal);
|
|
38517
38517
|
options.forceKillAfterDelay = normalizeForceKillAfterDelay(options.forceKillAfterDelay);
|
|
38518
38518
|
options.lines = options.lines.map((lines, fdNumber) => lines && !BINARY_ENCODINGS.has(options.encoding) && options.buffer[fdNumber]);
|
|
38519
|
-
if (
|
|
38519
|
+
if (N.platform === "win32" && path$1.basename(file, ".exe") === "cmd") commandArguments.unshift("/q");
|
|
38520
38520
|
return {
|
|
38521
38521
|
file,
|
|
38522
38522
|
commandArguments,
|
|
@@ -38543,7 +38543,7 @@ const addDefaultOptions = ({ extendEnv = true, preferLocal = false, cwd, localDi
|
|
|
38543
38543
|
});
|
|
38544
38544
|
const getEnv = ({ env: envOption, extendEnv, preferLocal, node, localDirectory, nodePath }) => {
|
|
38545
38545
|
const env$3 = extendEnv ? {
|
|
38546
|
-
...
|
|
38546
|
+
...N.env,
|
|
38547
38547
|
...envOption
|
|
38548
38548
|
} : envOption;
|
|
38549
38549
|
if (preferLocal || node) return npmRunPathEnv({
|
|
@@ -39531,12 +39531,12 @@ const guessStreamDirection = {
|
|
|
39531
39531
|
}
|
|
39532
39532
|
};
|
|
39533
39533
|
const getStandardStreamDirection = (value$1) => {
|
|
39534
|
-
if ([0,
|
|
39534
|
+
if ([0, N.stdin].includes(value$1)) return "input";
|
|
39535
39535
|
if ([
|
|
39536
39536
|
1,
|
|
39537
39537
|
2,
|
|
39538
|
-
|
|
39539
|
-
|
|
39538
|
+
N.stdout,
|
|
39539
|
+
N.stderr
|
|
39540
39540
|
].includes(value$1)) return "output";
|
|
39541
39541
|
};
|
|
39542
39542
|
const DEFAULT_DIRECTION = "output";
|
|
@@ -40600,9 +40600,9 @@ const addIpcMethods = (subprocess, { ipc }) => {
|
|
|
40600
40600
|
Object.assign(subprocess, getIpcMethods(subprocess, false, ipc));
|
|
40601
40601
|
};
|
|
40602
40602
|
const getIpcExport = () => {
|
|
40603
|
-
const anyProcess =
|
|
40603
|
+
const anyProcess = N;
|
|
40604
40604
|
const isSubprocess = true;
|
|
40605
|
-
const ipc =
|
|
40605
|
+
const ipc = N.channel !== void 0;
|
|
40606
40606
|
return {
|
|
40607
40607
|
...getIpcMethods(anyProcess, isSubprocess, ipc),
|
|
40608
40608
|
getCancelSignal: getCancelSignal$1.bind(void 0, {
|
|
@@ -41011,7 +41011,7 @@ if (process.platform === "linux") signals.push("SIGIO", "SIGPOLL", "SIGPWR", "SI
|
|
|
41011
41011
|
|
|
41012
41012
|
//#endregion
|
|
41013
41013
|
//#region ../../node_modules/.pnpm/signal-exit@4.1.0/node_modules/signal-exit/dist/mjs/index.js
|
|
41014
|
-
const processOk = (process$
|
|
41014
|
+
const processOk = (process$2) => !!process$2 && typeof process$2 === "object" && typeof process$2.removeListener === "function" && typeof process$2.emit === "function" && typeof process$2.reallyExit === "function" && typeof process$2.listeners === "function" && typeof process$2.kill === "function" && typeof process$2.pid === "number" && typeof process$2.on === "function";
|
|
41015
41015
|
const kExitEmitter = Symbol.for("signal-exit emitter");
|
|
41016
41016
|
const global$1 = globalThis;
|
|
41017
41017
|
const ObjectDefineProperty = Object.defineProperty.bind(Object);
|
|
@@ -41079,7 +41079,7 @@ var SignalExitFallback = class extends SignalExitBase {
|
|
|
41079
41079
|
};
|
|
41080
41080
|
var SignalExit = class extends SignalExitBase {
|
|
41081
41081
|
/* c8 ignore start */
|
|
41082
|
-
#hupSig = process$
|
|
41082
|
+
#hupSig = process$1.platform === "win32" ? "SIGINT" : "SIGHUP";
|
|
41083
41083
|
/* c8 ignore stop */
|
|
41084
41084
|
#emitter = new Emitter();
|
|
41085
41085
|
#process;
|
|
@@ -41087,15 +41087,15 @@ var SignalExit = class extends SignalExitBase {
|
|
|
41087
41087
|
#originalProcessReallyExit;
|
|
41088
41088
|
#sigListeners = {};
|
|
41089
41089
|
#loaded = false;
|
|
41090
|
-
constructor(process$
|
|
41090
|
+
constructor(process$2) {
|
|
41091
41091
|
super();
|
|
41092
|
-
this.#process = process$
|
|
41092
|
+
this.#process = process$2;
|
|
41093
41093
|
this.#sigListeners = {};
|
|
41094
41094
|
for (const sig$1 of signals) this.#sigListeners[sig$1] = () => {
|
|
41095
41095
|
const listeners = this.#process.listeners(sig$1);
|
|
41096
41096
|
let { count: count$1 } = this.#emitter;
|
|
41097
41097
|
/* c8 ignore start */
|
|
41098
|
-
const p$1 = process$
|
|
41098
|
+
const p$1 = process$2;
|
|
41099
41099
|
if (typeof p$1.__signal_exit_emitter__ === "object" && typeof p$1.__signal_exit_emitter__.count === "number") count$1 += p$1.__signal_exit_emitter__.count;
|
|
41100
41100
|
/* c8 ignore stop */
|
|
41101
41101
|
if (listeners.length === count$1) {
|
|
@@ -41103,11 +41103,11 @@ var SignalExit = class extends SignalExitBase {
|
|
|
41103
41103
|
const ret = this.#emitter.emit("exit", null, sig$1);
|
|
41104
41104
|
/* c8 ignore start */
|
|
41105
41105
|
const s = sig$1 === "SIGHUP" ? this.#hupSig : sig$1;
|
|
41106
|
-
if (!ret) process$
|
|
41106
|
+
if (!ret) process$2.kill(process$2.pid, s);
|
|
41107
41107
|
}
|
|
41108
41108
|
};
|
|
41109
|
-
this.#originalProcessReallyExit = process$
|
|
41110
|
-
this.#originalProcessEmit = process$
|
|
41109
|
+
this.#originalProcessReallyExit = process$2.reallyExit;
|
|
41110
|
+
this.#originalProcessEmit = process$2.emit;
|
|
41111
41111
|
}
|
|
41112
41112
|
onExit(cb, opts) {
|
|
41113
41113
|
/* c8 ignore start */
|
|
@@ -41174,8 +41174,8 @@ var SignalExit = class extends SignalExitBase {
|
|
|
41174
41174
|
} else return og.call(this.#process, ev, ...args);
|
|
41175
41175
|
}
|
|
41176
41176
|
};
|
|
41177
|
-
const process$
|
|
41178
|
-
const { onExit, load, unload } = signalExitWrap(processOk(process$
|
|
41177
|
+
const process$1 = globalThis.process;
|
|
41178
|
+
const { onExit, load, unload } = signalExitWrap(processOk(process$1) ? new SignalExit(process$1) : new SignalExitFallback());
|
|
41179
41179
|
|
|
41180
41180
|
//#endregion
|
|
41181
41181
|
//#region ../../node_modules/.pnpm/execa@9.5.2/node_modules/execa/lib/terminate/cleanup.js
|
|
@@ -42417,7 +42417,7 @@ const { sendMessage, getOneMessage, getEachMessage, getCancelSignal } = getIpcEx
|
|
|
42417
42417
|
//#endregion
|
|
42418
42418
|
//#region ../../node_modules/.pnpm/find-up-simple@1.0.1/node_modules/find-up-simple/index.js
|
|
42419
42419
|
const toPath$1 = (urlOrPath) => urlOrPath instanceof URL ? fileURLToPath(urlOrPath) : urlOrPath;
|
|
42420
|
-
async function findUp(name$1, { cwd =
|
|
42420
|
+
async function findUp(name$1, { cwd = N.cwd(), type = "file", stopAt } = {}) {
|
|
42421
42421
|
let directory = path$1.resolve(toPath$1(cwd) ?? "");
|
|
42422
42422
|
const { root } = path$1.parse(directory);
|
|
42423
42423
|
stopAt = path$1.resolve(directory, toPath$1(stopAt ?? root));
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hot-updater/cli-tools",
|
|
3
|
-
"version": "0.26.
|
|
3
|
+
"version": "0.26.2",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "CLI utilities for Hot Updater",
|
|
6
6
|
"sideEffects": false,
|
|
@@ -40,8 +40,8 @@
|
|
|
40
40
|
},
|
|
41
41
|
"dependencies": {
|
|
42
42
|
"oxc-transform": "0.82.1",
|
|
43
|
-
"@hot-updater/core": "0.26.
|
|
44
|
-
"@hot-updater/plugin-core": "0.26.
|
|
43
|
+
"@hot-updater/core": "0.26.2",
|
|
44
|
+
"@hot-updater/plugin-core": "0.26.2"
|
|
45
45
|
},
|
|
46
46
|
"devDependencies": {
|
|
47
47
|
"@clack/prompts": "^1.0.1",
|
|
@@ -60,7 +60,7 @@
|
|
|
60
60
|
"typescript": "5.8.2",
|
|
61
61
|
"@types/semver": "^7.7.1",
|
|
62
62
|
"execa": "9.5.2",
|
|
63
|
-
"@hot-updater/test-utils": "0.26.
|
|
63
|
+
"@hot-updater/test-utils": "0.26.2"
|
|
64
64
|
},
|
|
65
65
|
"peerDependencies": {
|
|
66
66
|
"typescript": "*"
|