@hot-updater/cli-tools 0.29.2 → 0.29.3

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.mjs +28 -28
  2. package/package.json +3 -3
package/dist/index.mjs CHANGED
@@ -9,7 +9,7 @@ import fs$1 from "fs/promises";
9
9
  import assert from "assert";
10
10
  import crypto from "crypto";
11
11
  import { Buffer as Buffer$1 } from "buffer";
12
- import N, { execArgv, execPath, hrtime, platform, stdin, stdout } from "node:process";
12
+ import process$1, { execArgv, execPath, hrtime, platform, stdin, stdout } from "node:process";
13
13
  import * as k from "node:readline";
14
14
  import ot from "node:readline";
15
15
  import tty, { ReadStream } from "node:tty";
@@ -19279,7 +19279,7 @@ var dist_exports = /* @__PURE__ */ __exportAll({
19279
19279
  updateSettings: () => It$1
19280
19280
  });
19281
19281
  function me() {
19282
- 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";
19282
+ 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";
19283
19283
  }
19284
19284
  const et = me(), ct = () => process.env.CI === "true", Mt = (t) => t.isTTY === !0, C = (t, r) => et ? t : r, Rt = C("◆", "*"), dt = C("■", "x"), $t = 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 = C("◻", "[ ]"), Nt = C("▪", "•"), rt = C("─", "-"), mt = C("╮", "+"), Wt = C("├", "+"), pt = C("╯", "+"), gt = C("╰", "+"), Lt = C("╭", "+"), ft = C("●", "•"), Ft = C("◆", "*"), yt = C("▲", "!"), Et = C("■", "x"), W = (t) => {
19285
19285
  switch (t) {
@@ -19919,7 +19919,7 @@ ${import_picocolors.default.cyan(x)}
19919
19919
  `), o = a.reduce((n, c) => Math.max(M(c), n), 0);
19920
19920
  return J(t, r - (a.map(s).reduce((n, c) => Math.max(M(c), n), 0) - o), i);
19921
19921
  }, Ve = (t = "", r = "", s) => {
19922
- const i = s?.output ?? N.stdout, a = s?.withGuide ?? _.withGuide, o = s?.format ?? Ge, u = [
19922
+ const i = s?.output ?? process$1.stdout, a = s?.withGuide ?? _.withGuide, o = s?.format ?? Ge, u = [
19923
19923
  "",
19924
19924
  ...ke(t, rt$1(i) - 6, o).split(`
19925
19925
  `).map(o),
@@ -20849,13 +20849,13 @@ function assembleStyles$1() {
20849
20849
  const ansiStyles$1 = assembleStyles$1();
20850
20850
  //#endregion
20851
20851
  //#region ../../node_modules/.pnpm/chalk@5.4.1/node_modules/chalk/source/vendor/supports-color/index.js
20852
- function hasFlag(flag, argv = globalThis.Deno ? globalThis.Deno.args : N.argv) {
20852
+ function hasFlag(flag, argv = globalThis.Deno ? globalThis.Deno.args : process$1.argv) {
20853
20853
  const prefix = flag.startsWith("-") ? "" : flag.length === 1 ? "-" : "--";
20854
20854
  const position = argv.indexOf(prefix + flag);
20855
20855
  const terminatorPosition = argv.indexOf("--");
20856
20856
  return position !== -1 && (terminatorPosition === -1 || position < terminatorPosition);
20857
20857
  }
20858
- const { env } = N;
20858
+ const { env } = process$1;
20859
20859
  let flagForceColor;
20860
20860
  if (hasFlag("no-color") || hasFlag("no-colors") || hasFlag("color=false") || hasFlag("color=never")) flagForceColor = 0;
20861
20861
  else if (hasFlag("color") || hasFlag("colors") || hasFlag("color=true") || hasFlag("color=always")) flagForceColor = 1;
@@ -20888,7 +20888,7 @@ function _supportsColor(haveStream, { streamIsTTY, sniffFlags = true } = {}) {
20888
20888
  if (haveStream && !streamIsTTY && forceColor === void 0) return 0;
20889
20889
  const min = forceColor || 0;
20890
20890
  if (env.TERM === "dumb") return min;
20891
- if (N.platform === "win32") {
20891
+ if (process$1.platform === "win32") {
20892
20892
  const osRelease = os.release().split(".");
20893
20893
  if (Number(osRelease[0]) >= 10 && Number(osRelease[2]) >= 10586) return Number(osRelease[2]) >= 14931 ? 3 : 2;
20894
20894
  return 1;
@@ -21645,7 +21645,7 @@ const NEWLINE = "\n";
21645
21645
  const PAD = " ";
21646
21646
  const NONE = "none";
21647
21647
  const terminalColumns = () => {
21648
- const { env, stdout, stderr } = N;
21648
+ const { env, stdout, stderr } = process$1;
21649
21649
  if (stdout?.columns) return stdout.columns;
21650
21650
  if (stderr?.columns) return stderr.columns;
21651
21651
  if (env.COLUMNS) return Number.parseInt(env.COLUMNS, 10);
@@ -21788,8 +21788,8 @@ const boxContent = (content, contentWidth, options) => {
21788
21788
  return result;
21789
21789
  };
21790
21790
  const sanitizeOptions = (options) => {
21791
- if (options.fullscreen && N?.stdout) {
21792
- let newDimensions = [N.stdout.columns, N.stdout.rows];
21791
+ if (options.fullscreen && process$1?.stdout) {
21792
+ let newDimensions = [process$1.stdout.columns, process$1.stdout.rows];
21793
21793
  if (typeof options.fullscreen === "function") newDimensions = options.fullscreen(...newDimensions);
21794
21794
  options.width ||= newDimensions[0];
21795
21795
  options.height ||= newDimensions[1];
@@ -36006,9 +36006,9 @@ const getSubprocessResult = ({ stdout }) => {
36006
36006
  //#region ../../node_modules/.pnpm/execa@9.5.2/node_modules/execa/lib/utils/standard-stream.js
36007
36007
  const isStandardStream = (stream) => STANDARD_STREAMS.includes(stream);
36008
36008
  const STANDARD_STREAMS = [
36009
- N.stdin,
36010
- N.stdout,
36011
- N.stderr
36009
+ process$1.stdin,
36010
+ process$1.stdout,
36011
+ process$1.stderr
36012
36012
  ];
36013
36013
  const STANDARD_STREAMS_ALIASES = [
36014
36014
  "stdin",
@@ -36129,9 +36129,9 @@ const NO_ESCAPE_REGEXP = /^[\w./-]+$/;
36129
36129
  //#endregion
36130
36130
  //#region ../../node_modules/.pnpm/is-unicode-supported@2.1.0/node_modules/is-unicode-supported/index.js
36131
36131
  function isUnicodeSupported() {
36132
- const { env } = N;
36132
+ const { env } = process$1;
36133
36133
  const { TERM, TERM_PROGRAM } = env;
36134
- if (N.platform !== "win32") return TERM !== "linux";
36134
+ if (process$1.platform !== "win32") return TERM !== "linux";
36135
36135
  return Boolean(env.WT_SESSION) || Boolean(env.TERMINUS_SUBLIME) || env.ConEmuTask === "{cmd::Cmder}" || TERM_PROGRAM === "Terminus-Sublime" || TERM_PROGRAM === "vscode" || TERM === "xterm-256color" || TERM === "alacritty" || TERM === "rxvt-unicode" || TERM === "rxvt-unicode-256color" || env.TERMINAL_EMULATOR === "JetBrains-JediTerm";
36136
36136
  }
36137
36137
  //#endregion
@@ -37024,7 +37024,7 @@ function traversePathUp(startPath) {
37024
37024
  }
37025
37025
  //#endregion
37026
37026
  //#region ../../node_modules/.pnpm/npm-run-path@6.0.0/node_modules/npm-run-path/index.js
37027
- const npmRunPath = ({ cwd = N.cwd(), path: pathOption = N.env[pathKey()], preferLocal = true, execPath = N.execPath, addExecPath = true } = {}) => {
37027
+ const npmRunPath = ({ cwd = process$1.cwd(), path: pathOption = process$1.env[pathKey()], preferLocal = true, execPath = process$1.execPath, addExecPath = true } = {}) => {
37028
37028
  const cwdPath = path$1.resolve(toPath$2(cwd));
37029
37029
  const result = [];
37030
37030
  const pathParts = pathOption.split(path$1.delimiter);
@@ -37042,7 +37042,7 @@ const applyExecPath = (result, pathParts, execPath, cwdPath) => {
37042
37042
  const pathPart = path$1.resolve(cwdPath, toPath$2(execPath), "..");
37043
37043
  if (!pathParts.includes(pathPart)) result.push(pathPart);
37044
37044
  };
37045
- const npmRunPathEnv = ({ env = N.env, ...options } = {}) => {
37045
+ const npmRunPathEnv = ({ env = process$1.env, ...options } = {}) => {
37046
37046
  env = { ...env };
37047
37047
  const pathName = pathKey({ env });
37048
37048
  options.path = env[pathName];
@@ -38149,7 +38149,7 @@ const normalizeCwd = (cwd = getDefaultCwd()) => {
38149
38149
  };
38150
38150
  const getDefaultCwd = () => {
38151
38151
  try {
38152
- return N.cwd();
38152
+ return process$1.cwd();
38153
38153
  } catch (error) {
38154
38154
  error.message = `The current directory does not exist.\n${error.message}`;
38155
38155
  throw error;
@@ -38183,7 +38183,7 @@ const normalizeOptions = (filePath, rawArguments, rawOptions) => {
38183
38183
  options.killSignal = normalizeKillSignal(options.killSignal);
38184
38184
  options.forceKillAfterDelay = normalizeForceKillAfterDelay(options.forceKillAfterDelay);
38185
38185
  options.lines = options.lines.map((lines, fdNumber) => lines && !BINARY_ENCODINGS.has(options.encoding) && options.buffer[fdNumber]);
38186
- if (N.platform === "win32" && path$1.basename(file, ".exe") === "cmd") commandArguments.unshift("/q");
38186
+ if (process$1.platform === "win32" && path$1.basename(file, ".exe") === "cmd") commandArguments.unshift("/q");
38187
38187
  return {
38188
38188
  file,
38189
38189
  commandArguments,
@@ -38210,7 +38210,7 @@ const addDefaultOptions = ({ extendEnv = true, preferLocal = false, cwd, localDi
38210
38210
  });
38211
38211
  const getEnv = ({ env: envOption, extendEnv, preferLocal, node, localDirectory, nodePath }) => {
38212
38212
  const env = extendEnv ? {
38213
- ...N.env,
38213
+ ...process$1.env,
38214
38214
  ...envOption
38215
38215
  } : envOption;
38216
38216
  if (preferLocal || node) return npmRunPathEnv({
@@ -39177,12 +39177,12 @@ const guessStreamDirection = {
39177
39177
  }
39178
39178
  };
39179
39179
  const getStandardStreamDirection = (value) => {
39180
- if ([0, N.stdin].includes(value)) return "input";
39180
+ if ([0, process$1.stdin].includes(value)) return "input";
39181
39181
  if ([
39182
39182
  1,
39183
39183
  2,
39184
- N.stdout,
39185
- N.stderr
39184
+ process$1.stdout,
39185
+ process$1.stderr
39186
39186
  ].includes(value)) return "output";
39187
39187
  };
39188
39188
  const DEFAULT_DIRECTION = "output";
@@ -40222,9 +40222,9 @@ const addIpcMethods = (subprocess, { ipc }) => {
40222
40222
  Object.assign(subprocess, getIpcMethods(subprocess, false, ipc));
40223
40223
  };
40224
40224
  const getIpcExport = () => {
40225
- const anyProcess = N;
40225
+ const anyProcess = process$1;
40226
40226
  const isSubprocess = true;
40227
- const ipc = N.channel !== void 0;
40227
+ const ipc = process$1.channel !== void 0;
40228
40228
  return {
40229
40229
  ...getIpcMethods(anyProcess, isSubprocess, ipc),
40230
40230
  getCancelSignal: getCancelSignal$1.bind(void 0, {
@@ -40694,7 +40694,7 @@ var SignalExitFallback = class extends SignalExitBase {
40694
40694
  };
40695
40695
  var SignalExit = class extends SignalExitBase {
40696
40696
  /* c8 ignore start */
40697
- #hupSig = process$1.platform === "win32" ? "SIGINT" : "SIGHUP";
40697
+ #hupSig = process$2.platform === "win32" ? "SIGINT" : "SIGHUP";
40698
40698
  /* c8 ignore stop */
40699
40699
  #emitter = new Emitter();
40700
40700
  #process;
@@ -40789,8 +40789,8 @@ var SignalExit = class extends SignalExitBase {
40789
40789
  } else return og.call(this.#process, ev, ...args);
40790
40790
  }
40791
40791
  };
40792
- const process$1 = globalThis.process;
40793
- const { onExit, load, unload } = signalExitWrap(processOk(process$1) ? new SignalExit(process$1) : new SignalExitFallback());
40792
+ const process$2 = globalThis.process;
40793
+ const { onExit, load, unload } = signalExitWrap(processOk(process$2) ? new SignalExit(process$2) : new SignalExitFallback());
40794
40794
  //#endregion
40795
40795
  //#region ../../node_modules/.pnpm/execa@9.5.2/node_modules/execa/lib/terminate/cleanup.js
40796
40796
  const cleanupOnExit = (subprocess, { cleanup, detached }, { signal }) => {
@@ -42002,7 +42002,7 @@ const { sendMessage, getOneMessage, getEachMessage, getCancelSignal } = getIpcEx
42002
42002
  //#endregion
42003
42003
  //#region ../../node_modules/.pnpm/find-up-simple@1.0.1/node_modules/find-up-simple/index.js
42004
42004
  const toPath$1 = (urlOrPath) => urlOrPath instanceof URL ? fileURLToPath(urlOrPath) : urlOrPath;
42005
- async function findUp(name, { cwd = N.cwd(), type = "file", stopAt } = {}) {
42005
+ async function findUp(name, { cwd = process$1.cwd(), type = "file", stopAt } = {}) {
42006
42006
  let directory = path$1.resolve(toPath$1(cwd) ?? "");
42007
42007
  const { root } = path$1.parse(directory);
42008
42008
  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.29.2",
3
+ "version": "0.29.3",
4
4
  "type": "module",
5
5
  "description": "CLI utilities for Hot Updater",
6
6
  "sideEffects": false,
@@ -41,7 +41,7 @@
41
41
  "dependencies": {
42
42
  "oxc-transform": "0.121.0",
43
43
  "unconfig": "7.5.0",
44
- "@hot-updater/plugin-core": "0.29.2"
44
+ "@hot-updater/plugin-core": "0.29.3"
45
45
  },
46
46
  "devDependencies": {
47
47
  "@clack/prompts": "1.0.1",
@@ -58,7 +58,7 @@
58
58
  "tar": "^7.5.1",
59
59
  "typescript": "5.8.2",
60
60
  "workspace-tools": "^0.36.4",
61
- "@hot-updater/test-utils": "0.29.2"
61
+ "@hot-updater/test-utils": "0.29.3"
62
62
  },
63
63
  "inlinedDependencies": {
64
64
  "@babel/code-frame": "7.29.0",