@hot-updater/cli-tools 0.24.2 → 0.24.4

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.
Files changed (2) hide show
  1. package/dist/index.js +43 -43
  2. package/package.json +3 -3
package/dist/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import { createRequire } from "node:module";
2
- import process$1, { stdin, stdout } from "node:process";
2
+ import y, { stdin, stdout } from "node:process";
3
3
  import os from "node:os";
4
4
  import tty from "node:tty";
5
5
  import fs from "fs/promises";
@@ -301,13 +301,13 @@ var ansi_styles_default$1 = ansiStyles$1;
301
301
 
302
302
  //#endregion
303
303
  //#region ../../node_modules/.pnpm/chalk@5.4.1/node_modules/chalk/source/vendor/supports-color/index.js
304
- function hasFlag(flag, argv$1 = globalThis.Deno ? globalThis.Deno.args : process$1.argv) {
304
+ function hasFlag(flag, argv$1 = globalThis.Deno ? globalThis.Deno.args : y.argv) {
305
305
  const prefix = flag.startsWith("-") ? "" : flag.length === 1 ? "-" : "--";
306
306
  const position = argv$1.indexOf(prefix + flag);
307
307
  const terminatorPosition = argv$1.indexOf("--");
308
308
  return position !== -1 && (terminatorPosition === -1 || position < terminatorPosition);
309
309
  }
310
- const { env: env$2 } = process$1;
310
+ const { env: env$2 } = y;
311
311
  let flagForceColor;
312
312
  if (hasFlag("no-color") || hasFlag("no-colors") || hasFlag("color=false") || hasFlag("color=never")) flagForceColor = 0;
313
313
  else if (hasFlag("color") || hasFlag("colors") || hasFlag("color=true") || hasFlag("color=always")) flagForceColor = 1;
@@ -340,7 +340,7 @@ function _supportsColor(haveStream, { streamIsTTY, sniffFlags = true } = {}) {
340
340
  if (haveStream && !streamIsTTY && forceColor === void 0) return 0;
341
341
  const min = forceColor || 0;
342
342
  if (env$2.TERM === "dumb") return min;
343
- if (process$1.platform === "win32") {
343
+ if (y.platform === "win32") {
344
344
  const osRelease = os.release().split(".");
345
345
  if (Number(osRelease[0]) >= 10 && Number(osRelease[2]) >= 10586) return Number(osRelease[2]) >= 14931 ? 3 : 2;
346
346
  return 1;
@@ -1122,7 +1122,7 @@ const NEWLINE$2 = "\n";
1122
1122
  const PAD = " ";
1123
1123
  const NONE = "none";
1124
1124
  const terminalColumns = () => {
1125
- const { env: env$3, stdout: stdout$1, stderr } = process$1;
1125
+ const { env: env$3, stdout: stdout$1, stderr } = y;
1126
1126
  if (stdout$1?.columns) return stdout$1.columns;
1127
1127
  if (stderr?.columns) return stderr.columns;
1128
1128
  if (env$3.COLUMNS) return Number.parseInt(env$3.COLUMNS, 10);
@@ -1265,8 +1265,8 @@ const boxContent = (content, contentWidth, options) => {
1265
1265
  return result;
1266
1266
  };
1267
1267
  const sanitizeOptions = (options) => {
1268
- if (options.fullscreen && process$1?.stdout) {
1269
- let newDimensions = [process$1.stdout.columns, process$1.stdout.rows];
1268
+ if (options.fullscreen && y?.stdout) {
1269
+ let newDimensions = [y.stdout.columns, y.stdout.rows];
1270
1270
  if (typeof options.fullscreen === "function") newDimensions = options.fullscreen(...newDimensions);
1271
1271
  options.width ||= newDimensions[0];
1272
1272
  options.height ||= newDimensions[1];
@@ -12756,9 +12756,9 @@ var require_lockfile$1 = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/
12756
12756
  }
12757
12757
  exports$1.MessageError = MessageError;
12758
12758
  class ProcessSpawnError extends MessageError {
12759
- constructor(msg$3, code$1, process$2) {
12759
+ constructor(msg$3, code$1, process$1) {
12760
12760
  super(msg$3, code$1);
12761
- this.process = process$2;
12761
+ this.process = process$1;
12762
12762
  }
12763
12763
  }
12764
12764
  exports$1.ProcessSpawnError = ProcessSpawnError;
@@ -16320,7 +16320,7 @@ var require_lockfile$1 = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/
16320
16320
  var html = __webpack_require__(102);
16321
16321
  var cel = __webpack_require__(68);
16322
16322
  var global$1 = __webpack_require__(11);
16323
- var process$2 = global$1.process;
16323
+ var process$1 = global$1.process;
16324
16324
  var setTask = global$1.setImmediate;
16325
16325
  var clearTask = global$1.clearImmediate;
16326
16326
  var MessageChannel$1 = global$1.MessageChannel;
@@ -16354,8 +16354,8 @@ var require_lockfile$1 = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/
16354
16354
  clearTask = function clearImmediate(id) {
16355
16355
  delete queue$1[id];
16356
16356
  };
16357
- if (__webpack_require__(47)(process$2) == "process") defer$1 = function(id) {
16358
- process$2.nextTick(ctx(run, id, 1));
16357
+ if (__webpack_require__(47)(process$1) == "process") defer$1 = function(id) {
16358
+ process$1.nextTick(ctx(run, id, 1));
16359
16359
  };
16360
16360
  else if (Dispatch && Dispatch.now) defer$1 = function(id) {
16361
16361
  Dispatch.now(ctx(run, id, 1));
@@ -17385,11 +17385,11 @@ var require_lockfile$1 = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/
17385
17385
  function isPadded(el) {
17386
17386
  return /^-?0\d/.test(el);
17387
17387
  }
17388
- function lte(i$3, y$1) {
17389
- return i$3 <= y$1;
17388
+ function lte(i$3, y$2) {
17389
+ return i$3 <= y$2;
17390
17390
  }
17391
- function gte(i$3, y$1) {
17392
- return i$3 >= y$1;
17391
+ function gte(i$3, y$2) {
17392
+ return i$3 >= y$2;
17393
17393
  }
17394
17394
  function expand$2(str, isTop) {
17395
17395
  var expansions = [];
@@ -17425,17 +17425,17 @@ var require_lockfile$1 = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/
17425
17425
  var N$1;
17426
17426
  if (isSequence) {
17427
17427
  var x$2 = numeric(n[0]);
17428
- var y$1 = numeric(n[1]);
17428
+ var y$2 = numeric(n[1]);
17429
17429
  var width = Math.max(n[0].length, n[1].length);
17430
17430
  var incr = n.length == 3 ? Math.abs(numeric(n[2])) : 1;
17431
17431
  var test = lte;
17432
- if (y$1 < x$2) {
17432
+ if (y$2 < x$2) {
17433
17433
  incr *= -1;
17434
17434
  test = gte;
17435
17435
  }
17436
17436
  var pad$1 = n.some(isPadded);
17437
17437
  N$1 = [];
17438
- for (var i$3 = x$2; test(i$3, y$1); i$3 += incr) {
17438
+ for (var i$3 = x$2; test(i$3, y$2); i$3 += incr) {
17439
17439
  var c$1;
17440
17440
  if (isAlphaSequence) {
17441
17441
  c$1 = String.fromCharCode(i$3);
@@ -17676,14 +17676,14 @@ var require_lockfile$1 = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/
17676
17676
  var global$1 = __webpack_require__(11);
17677
17677
  var macrotask = __webpack_require__(109).set;
17678
17678
  var Observer = global$1.MutationObserver || global$1.WebKitMutationObserver;
17679
- var process$2 = global$1.process;
17679
+ var process$1 = global$1.process;
17680
17680
  var Promise$2 = global$1.Promise;
17681
- var isNode = __webpack_require__(47)(process$2) == "process";
17681
+ var isNode = __webpack_require__(47)(process$1) == "process";
17682
17682
  module$1.exports = function() {
17683
17683
  var head, last, notify;
17684
17684
  var flush = function() {
17685
17685
  var parent, fn;
17686
- if (isNode && (parent = process$2.domain)) parent.exit();
17686
+ if (isNode && (parent = process$1.domain)) parent.exit();
17687
17687
  while (head) {
17688
17688
  fn = head.fn;
17689
17689
  head = head.next;
@@ -17699,7 +17699,7 @@ var require_lockfile$1 = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/
17699
17699
  if (parent) parent.enter();
17700
17700
  };
17701
17701
  if (isNode) notify = function() {
17702
- process$2.nextTick(flush);
17702
+ process$1.nextTick(flush);
17703
17703
  };
17704
17704
  else if (Observer && !(global$1.navigator && global$1.navigator.standalone)) {
17705
17705
  var toggle = true;
@@ -17926,11 +17926,11 @@ var require_lockfile$1 = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/
17926
17926
  var promiseResolve = __webpack_require__(105);
17927
17927
  var PROMISE = "Promise";
17928
17928
  var TypeError$1 = global$1.TypeError;
17929
- var process$2 = global$1.process;
17930
- var versions = process$2 && process$2.versions;
17929
+ var process$1 = global$1.process;
17930
+ var versions = process$1 && process$1.versions;
17931
17931
  var v8 = versions && versions.v8 || "";
17932
17932
  var $Promise = global$1[PROMISE];
17933
- var isNode = classof(process$2) == "process";
17933
+ var isNode = classof(process$1) == "process";
17934
17934
  var empty = function() {};
17935
17935
  var Internal, newGenericPromiseCapability, OwnPromiseCapability, Wrapper;
17936
17936
  var newPromiseCapability = newGenericPromiseCapability = newPromiseCapabilityModule.f;
@@ -17998,7 +17998,7 @@ var require_lockfile$1 = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/
17998
17998
  var result, handler, console$1;
17999
17999
  if (unhandled) {
18000
18000
  result = perform(function() {
18001
- if (isNode) process$2.emit("unhandledRejection", value$1, promise$1);
18001
+ if (isNode) process$1.emit("unhandledRejection", value$1, promise$1);
18002
18002
  else if (handler = global$1.onunhandledrejection) handler({
18003
18003
  promise: promise$1,
18004
18004
  reason: value$1
@@ -18017,7 +18017,7 @@ var require_lockfile$1 = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/
18017
18017
  var onHandleUnhandled = function(promise$1) {
18018
18018
  task.call(global$1, function() {
18019
18019
  var handler;
18020
- if (isNode) process$2.emit("rejectionHandled", promise$1);
18020
+ if (isNode) process$1.emit("rejectionHandled", promise$1);
18021
18021
  else if (handler = global$1.onrejectionhandled) handler({
18022
18022
  promise: promise$1,
18023
18023
  reason: promise$1._v
@@ -18090,7 +18090,7 @@ var require_lockfile$1 = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/
18090
18090
  var reaction = newPromiseCapability(speciesConstructor(this, $Promise));
18091
18091
  reaction.ok = typeof onFulfilled == "function" ? onFulfilled : true;
18092
18092
  reaction.fail = typeof onRejected == "function" && onRejected;
18093
- reaction.domain = isNode ? process$2.domain : void 0;
18093
+ reaction.domain = isNode ? process$1.domain : void 0;
18094
18094
  this._c.push(reaction);
18095
18095
  if (this._a) this._a.push(reaction);
18096
18096
  if (this._s) notify(this, false);
@@ -19165,7 +19165,7 @@ var require_lockfile$1 = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/
19165
19165
  var m$1 = s * 60;
19166
19166
  var h$1 = m$1 * 60;
19167
19167
  var d$2 = h$1 * 24;
19168
- var y$1 = d$2 * 365.25;
19168
+ var y$2 = d$2 * 365.25;
19169
19169
  /**
19170
19170
  * Parse or format the given `val`.
19171
19171
  *
@@ -19204,7 +19204,7 @@ var require_lockfile$1 = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/
19204
19204
  case "year":
19205
19205
  case "yrs":
19206
19206
  case "yr":
19207
- case "y": return n * y$1;
19207
+ case "y": return n * y$2;
19208
19208
  case "days":
19209
19209
  case "day":
19210
19210
  case "d": return n * d$2;
@@ -43500,7 +43500,7 @@ var require_babel = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/jiti@
43500
43500
  jsesc.version = "2.5.2", module$1.exports = jsesc;
43501
43501
  },
43502
43502
  "./node_modules/.pnpm/ms@2.1.2/node_modules/ms/index.js": (module$1) => {
43503
- var s = 1e3, m$1 = 60 * s, h$1 = 60 * m$1, d$2 = 24 * h$1, w$1 = 7 * d$2, y$1 = 365.25 * d$2;
43503
+ var s = 1e3, m$1 = 60 * s, h$1 = 60 * m$1, d$2 = 24 * h$1, w$1 = 7 * d$2, y$2 = 365.25 * d$2;
43504
43504
  function plural(ms, msAbs, n, name$1) {
43505
43505
  var isPlural = msAbs >= 1.5 * n;
43506
43506
  return Math.round(ms / n) + " " + name$1 + (isPlural ? "s" : "");
@@ -43518,7 +43518,7 @@ var require_babel = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/jiti@
43518
43518
  case "year":
43519
43519
  case "yrs":
43520
43520
  case "yr":
43521
- case "y": return n * y$1;
43521
+ case "y": return n * y$2;
43522
43522
  case "weeks":
43523
43523
  case "week":
43524
43524
  case "w": return n * w$1;
@@ -78589,16 +78589,16 @@ var require_src = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/sistera
78589
78589
  const CSI = `${ESC}[`;
78590
78590
  const beep = "\x07";
78591
78591
  const cursor = {
78592
- to(x$2, y$1) {
78593
- if (!y$1) return `${CSI}${x$2 + 1}G`;
78594
- return `${CSI}${y$1 + 1};${x$2 + 1}H`;
78592
+ to(x$2, y$2) {
78593
+ if (!y$2) return `${CSI}${x$2 + 1}G`;
78594
+ return `${CSI}${y$2 + 1};${x$2 + 1}H`;
78595
78595
  },
78596
- move(x$2, y$1) {
78596
+ move(x$2, y$2) {
78597
78597
  let ret = "";
78598
78598
  if (x$2 < 0) ret += `${CSI}${-x$2}D`;
78599
78599
  else if (x$2 > 0) ret += `${CSI}${x$2}C`;
78600
- if (y$1 < 0) ret += `${CSI}${-y$1}A`;
78601
- else if (y$1 > 0) ret += `${CSI}${y$1}B`;
78600
+ if (y$2 < 0) ret += `${CSI}${-y$2}A`;
78601
+ else if (y$2 > 0) ret += `${CSI}${y$2}B`;
78602
78602
  return ret;
78603
78603
  },
78604
78604
  up: (count = 1) => `${CSI}${count}A`,
@@ -78839,13 +78839,13 @@ function rD() {
78839
78839
  }
78840
78840
  }), r;
78841
78841
  }
78842
- const ED = rD(), d$1 = new Set(["\x1B", "›"]), oD = 39, y = "\x07", V$1 = "[", nD = "]", G$1 = "m", _$1 = `${nD}8;;`, z = (e$1) => `${d$1.values().next().value}${V$1}${e$1}${G$1}`, K$1 = (e$1) => `${d$1.values().next().value}${_$1}${e$1}${y}`, aD = (e$1) => e$1.split(" ").map((u$1) => p(u$1)), k$1 = (e$1, u$1, t) => {
78842
+ const ED = rD(), d$1 = new Set(["\x1B", "›"]), oD = 39, y$1 = "\x07", V$1 = "[", nD = "]", G$1 = "m", _$1 = `${nD}8;;`, z = (e$1) => `${d$1.values().next().value}${V$1}${e$1}${G$1}`, K$1 = (e$1) => `${d$1.values().next().value}${_$1}${e$1}${y$1}`, aD = (e$1) => e$1.split(" ").map((u$1) => p(u$1)), k$1 = (e$1, u$1, t) => {
78843
78843
  const F$1 = [...u$1];
78844
78844
  let s = !1, i$3 = !1, D$1 = p(P$1(e$1[e$1.length - 1]));
78845
78845
  for (const [C$1, n] of F$1.entries()) {
78846
78846
  const E = p(n);
78847
78847
  if (D$1 + E <= t ? e$1[e$1.length - 1] += n : (e$1.push(n), D$1 = 0), d$1.has(n) && (s = !0, i$3 = F$1.slice(C$1 + 1).join("").startsWith(_$1)), s) {
78848
- i$3 ? n === y && (s = !1, i$3 = !1) : n === G$1 && (s = !1);
78848
+ i$3 ? n === y$1 && (s = !1, i$3 = !1) : n === G$1 && (s = !1);
78849
78849
  continue;
78850
78850
  }
78851
78851
  D$1 += E, D$1 === t && C$1 < F$1.length - 1 && (e$1.push(""), D$1 = 0);
@@ -78887,7 +78887,7 @@ const ED = rD(), d$1 = new Set(["\x1B", "›"]), oD = 39, y = "\x07", V$1 = "[",
78887
78887
  `)];
78888
78888
  for (const [E, a] of n.entries()) {
78889
78889
  if (F$1 += a, d$1.has(a)) {
78890
- const { groups: c$1 } = (/* @__PURE__ */ new RegExp(`(?:\\${V$1}(?<code>\\d+)m|\\${_$1}(?<uri>.*)${y})`)).exec(n.slice(E).join("")) || { groups: {} };
78890
+ const { groups: c$1 } = (/* @__PURE__ */ new RegExp(`(?:\\${V$1}(?<code>\\d+)m|\\${_$1}(?<uri>.*)${y$1})`)).exec(n.slice(E).join("")) || { groups: {} };
78891
78891
  if (c$1.code !== void 0) {
78892
78892
  const f = Number.parseFloat(c$1.code);
78893
78893
  s = f === oD ? void 0 : f;
@@ -79322,7 +79322,7 @@ var dist_exports = /* @__PURE__ */ __export({
79322
79322
  var import_picocolors = /* @__PURE__ */ __toESM(require_picocolors(), 1);
79323
79323
  var import_src = /* @__PURE__ */ __toESM(require_src(), 1);
79324
79324
  function ce() {
79325
- return process$1.platform !== "win32" ? process$1.env.TERM !== "linux" : !!process$1.env.CI || !!process$1.env.WT_SESSION || !!process$1.env.TERMINUS_SUBLIME || process$1.env.ConEmuTask === "{cmd::Cmder}" || process$1.env.TERM_PROGRAM === "Terminus-Sublime" || process$1.env.TERM_PROGRAM === "vscode" || process$1.env.TERM === "xterm-256color" || process$1.env.TERM === "alacritty" || process$1.env.TERMINAL_EMULATOR === "JetBrains-JediTerm";
79325
+ return y.platform !== "win32" ? y.env.TERM !== "linux" : !!y.env.CI || !!y.env.WT_SESSION || !!y.env.TERMINUS_SUBLIME || y.env.ConEmuTask === "{cmd::Cmder}" || y.env.TERM_PROGRAM === "Terminus-Sublime" || y.env.TERM_PROGRAM === "vscode" || y.env.TERM === "xterm-256color" || y.env.TERM === "alacritty" || y.env.TERMINAL_EMULATOR === "JetBrains-JediTerm";
79326
79326
  }
79327
79327
  const V = ce(), u = (t, n) => V ? t : n, le = u("◆", "*"), L = u("■", "x"), W = u("▲", "x"), C = u("◇", "o"), ue = u("┌", "T"), o = u("│", "|"), d = u("└", "—"), k = u("●", ">"), P = u("○", " "), A = u("◻", "[•]"), T = u("◼", "[+]"), F = u("◻", "[ ]"), $e = u("▪", "•"), _ = u("─", "-"), me = u("╮", "+"), de = u("├", "+"), pe = u("╯", "+"), q = u("●", "•"), D = u("◆", "*"), U = u("▲", "!"), K = u("■", "x"), b = (t) => {
79328
79328
  switch (t) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hot-updater/cli-tools",
3
- "version": "0.24.2",
3
+ "version": "0.24.4",
4
4
  "type": "module",
5
5
  "description": "CLI utilities for Hot Updater",
6
6
  "sideEffects": false,
@@ -40,7 +40,7 @@
40
40
  },
41
41
  "dependencies": {
42
42
  "oxc-transform": "0.82.1",
43
- "@hot-updater/plugin-core": "0.24.2"
43
+ "@hot-updater/plugin-core": "0.24.4"
44
44
  },
45
45
  "devDependencies": {
46
46
  "@clack/prompts": "0.11.0",
@@ -55,7 +55,7 @@
55
55
  "workspace-tools": "^0.36.4",
56
56
  "@types/node": "^20",
57
57
  "typescript": "5.8.2",
58
- "@hot-updater/test-utils": "0.24.2"
58
+ "@hot-updater/test-utils": "0.24.4"
59
59
  },
60
60
  "peerDependencies": {
61
61
  "typescript": "*"