@lobehub/cli 0.0.210 → 0.0.211

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -15,7 +15,7 @@ import { Buffer as Buffer$1 } from "node:buffer";
15
15
  import * as net$1 from "node:net";
16
16
  import net, { BlockList, connect, createServer, isIP } from "node:net";
17
17
  import { scheduler, setImmediate as setImmediate$1, setTimeout as setTimeout$1 } from "node:timers/promises";
18
- import _w, { cwd, execArgv, execPath, hrtime, platform as platform$1 } from "node:process";
18
+ import process$1, { cwd, execArgv, execPath, hrtime, platform as platform$1 } from "node:process";
19
19
  import { URL as URL$1, fileURLToPath, pathToFileURL } from "node:url";
20
20
  import { finished, pipeline } from "node:stream/promises";
21
21
  import { Duplex, PassThrough, Readable, Transform, Writable, getDefaultHighWaterMark, pipeline as pipeline$1 } from "node:stream";
@@ -26,17 +26,17 @@ import http, { Agent, ServerResponse, createServer as createServer$1, request }
26
26
  import { createServer as createServer$2, request as request$1 } from "node:https";
27
27
  import zlib, { zstdDecompress } from "node:zlib";
28
28
  import { aborted, callbackify, debuglog, inspect, promisify, stripVTControlCharacters } from "node:util";
29
+ import { connect as connect$1, createSecureContext, rootCertificates } from "node:tls";
30
+ import { Http2ServerRequest, constants as constants$2 } from "node:http2";
31
+ import { AsyncLocalStorage } from "node:async_hooks";
29
32
  import { spawn as spawn$1 } from "child_process";
30
33
  import * as fs$6 from "fs";
31
34
  import { createRequire as createRequire$1 } from "module";
32
35
  import { homedir as homedir$1 } from "os";
33
36
  import * as path$5 from "path";
34
- import { AsyncLocalStorage } from "node:async_hooks";
35
- import { connect as connect$1, createSecureContext, rootCertificates } from "node:tls";
36
37
  import { StringDecoder } from "node:string_decoder";
37
38
  import tty from "node:tty";
38
39
  import { serialize } from "node:v8";
39
- import { Http2ServerRequest, constants as constants$2 } from "node:http2";
40
40
 
41
41
  //#region \0rolldown/runtime.js
42
42
  var __create$2 = Object.create;
@@ -24433,7 +24433,7 @@ var require_command = /* @__PURE__ */ __commonJSMin$2(((exports) => {
24433
24433
  const childProcess$2 = __require("node:child_process");
24434
24434
  const path$16 = __require("node:path");
24435
24435
  const fs$17 = __require("node:fs");
24436
- const process$2 = __require("node:process");
24436
+ const process$3 = __require("node:process");
24437
24437
  const { Argument, humanReadableArgName } = require_argument();
24438
24438
  const { CommanderError } = require_error$1();
24439
24439
  const { Help, stripColor } = require_help();
@@ -24485,13 +24485,13 @@ var require_command = /* @__PURE__ */ __commonJSMin$2(((exports) => {
24485
24485
  this._showSuggestionAfterError = true;
24486
24486
  this._savedState = null;
24487
24487
  this._outputConfiguration = {
24488
- writeOut: (str) => process$2.stdout.write(str),
24489
- writeErr: (str) => process$2.stderr.write(str),
24488
+ writeOut: (str) => process$3.stdout.write(str),
24489
+ writeErr: (str) => process$3.stderr.write(str),
24490
24490
  outputError: (str, write) => write(str),
24491
- getOutHelpWidth: () => process$2.stdout.isTTY ? process$2.stdout.columns : void 0,
24492
- getErrHelpWidth: () => process$2.stderr.isTTY ? process$2.stderr.columns : void 0,
24493
- getOutHasColors: () => useColor() ?? (process$2.stdout.isTTY && process$2.stdout.hasColors?.()),
24494
- getErrHasColors: () => useColor() ?? (process$2.stderr.isTTY && process$2.stderr.hasColors?.()),
24491
+ getOutHelpWidth: () => process$3.stdout.isTTY ? process$3.stdout.columns : void 0,
24492
+ getErrHelpWidth: () => process$3.stderr.isTTY ? process$3.stderr.columns : void 0,
24493
+ getOutHasColors: () => useColor() ?? (process$3.stdout.isTTY && process$3.stdout.hasColors?.()),
24494
+ getErrHasColors: () => useColor() ?? (process$3.stderr.isTTY && process$3.stderr.hasColors?.()),
24495
24495
  stripColor: (str) => stripColor(str)
24496
24496
  };
24497
24497
  this._hidden = false;
@@ -24849,7 +24849,7 @@ Expecting one of '${allowedValues.join("', '")}'`);
24849
24849
  */
24850
24850
  _exit(exitCode, code, message) {
24851
24851
  if (this._exitCallback) this._exitCallback(new CommanderError(exitCode, code, message));
24852
- process$2.exit(exitCode);
24852
+ process$3.exit(exitCode);
24853
24853
  }
24854
24854
  /**
24855
24855
  * Register callback `fn` for the command.
@@ -25188,11 +25188,11 @@ Expecting one of '${allowedValues.join("', '")}'`);
25188
25188
  if (argv !== void 0 && !Array.isArray(argv)) throw new Error("first parameter to parse must be array or undefined");
25189
25189
  parseOptions = parseOptions || {};
25190
25190
  if (argv === void 0 && parseOptions.from === void 0) {
25191
- if (process$2.versions?.electron) parseOptions.from = "electron";
25192
- const execArgv = process$2.execArgv ?? [];
25191
+ if (process$3.versions?.electron) parseOptions.from = "electron";
25192
+ const execArgv = process$3.execArgv ?? [];
25193
25193
  if (execArgv.includes("-e") || execArgv.includes("--eval") || execArgv.includes("-p") || execArgv.includes("--print")) parseOptions.from = "eval";
25194
25194
  }
25195
- if (argv === void 0) argv = process$2.argv;
25195
+ if (argv === void 0) argv = process$3.argv;
25196
25196
  this.rawArgs = argv.slice();
25197
25197
  let userArgs;
25198
25198
  switch (parseOptions.from) {
@@ -25202,7 +25202,7 @@ Expecting one of '${allowedValues.join("', '")}'`);
25202
25202
  userArgs = argv.slice(2);
25203
25203
  break;
25204
25204
  case "electron":
25205
- if (process$2.defaultApp) {
25205
+ if (process$3.defaultApp) {
25206
25206
  this._scriptPath = argv[1];
25207
25207
  userArgs = argv.slice(2);
25208
25208
  } else userArgs = argv.slice(1);
@@ -25367,16 +25367,16 @@ Expecting one of '${allowedValues.join("', '")}'`);
25367
25367
  }
25368
25368
  launchWithNode = sourceExt.includes(path$16.extname(executableFile));
25369
25369
  let proc;
25370
- if (process$2.platform !== "win32") if (launchWithNode) {
25370
+ if (process$3.platform !== "win32") if (launchWithNode) {
25371
25371
  args.unshift(executableFile);
25372
- args = incrementNodeInspectorPort(process$2.execArgv).concat(args);
25373
- proc = childProcess$2.spawn(process$2.argv[0], args, { stdio: "inherit" });
25372
+ args = incrementNodeInspectorPort(process$3.execArgv).concat(args);
25373
+ proc = childProcess$2.spawn(process$3.argv[0], args, { stdio: "inherit" });
25374
25374
  } else proc = childProcess$2.spawn(executableFile, args, { stdio: "inherit" });
25375
25375
  else {
25376
25376
  this._checkForMissingExecutable(executableFile, executableDir, subcommand._name);
25377
25377
  args.unshift(executableFile);
25378
- args = incrementNodeInspectorPort(process$2.execArgv).concat(args);
25379
- proc = childProcess$2.spawn(process$2.execPath, args, { stdio: "inherit" });
25378
+ args = incrementNodeInspectorPort(process$3.execArgv).concat(args);
25379
+ proc = childProcess$2.spawn(process$3.execPath, args, { stdio: "inherit" });
25380
25380
  }
25381
25381
  if (!proc.killed) [
25382
25382
  "SIGUSR1",
@@ -25385,20 +25385,20 @@ Expecting one of '${allowedValues.join("', '")}'`);
25385
25385
  "SIGINT",
25386
25386
  "SIGHUP"
25387
25387
  ].forEach((signal) => {
25388
- process$2.on(signal, () => {
25388
+ process$3.on(signal, () => {
25389
25389
  if (proc.killed === false && proc.exitCode === null) proc.kill(signal);
25390
25390
  });
25391
25391
  });
25392
25392
  const exitCallback = this._exitCallback;
25393
25393
  proc.on("close", (code) => {
25394
25394
  code = code ?? 1;
25395
- if (!exitCallback) process$2.exit(code);
25395
+ if (!exitCallback) process$3.exit(code);
25396
25396
  else exitCallback(new CommanderError(code, "commander.executeSubCommandAsync", "(close)"));
25397
25397
  });
25398
25398
  proc.on("error", (err) => {
25399
25399
  if (err.code === "ENOENT") this._checkForMissingExecutable(executableFile, executableDir, subcommand._name);
25400
25400
  else if (err.code === "EACCES") throw new Error(`'${executableFile}' not executable`);
25401
- if (!exitCallback) process$2.exit(1);
25401
+ if (!exitCallback) process$3.exit(1);
25402
25402
  else {
25403
25403
  const wrappedError = new CommanderError(1, "commander.executeSubCommandAsync", "(error)");
25404
25404
  wrappedError.nestedError = err;
@@ -25807,13 +25807,13 @@ Expecting one of '${allowedValues.join("', '")}'`);
25807
25807
  */
25808
25808
  _parseOptionsEnv() {
25809
25809
  this.options.forEach((option) => {
25810
- if (option.envVar && option.envVar in process$2.env) {
25810
+ if (option.envVar && option.envVar in process$3.env) {
25811
25811
  const optionKey = option.attributeName();
25812
25812
  if (this.getOptionValue(optionKey) === void 0 || [
25813
25813
  "default",
25814
25814
  "config",
25815
25815
  "env"
25816
- ].includes(this.getOptionValueSource(optionKey))) if (option.required || option.optional) this.emit(`optionEnv:${option.name()}`, process$2.env[option.envVar]);
25816
+ ].includes(this.getOptionValueSource(optionKey))) if (option.required || option.optional) this.emit(`optionEnv:${option.name()}`, process$3.env[option.envVar]);
25817
25817
  else this.emit(`optionEnv:${option.name()}`);
25818
25818
  }
25819
25819
  });
@@ -26230,7 +26230,7 @@ Expecting one of '${allowedValues.join("', '")}'`);
26230
26230
  */
26231
26231
  help(contextOptions) {
26232
26232
  this.outputHelp(contextOptions);
26233
- let exitCode = Number(process$2.exitCode ?? 0);
26233
+ let exitCode = Number(process$3.exitCode ?? 0);
26234
26234
  if (exitCode === 0 && contextOptions && typeof contextOptions !== "function" && contextOptions.error) exitCode = 1;
26235
26235
  this._exit(exitCode, "commander.help", "(outputHelp)");
26236
26236
  }
@@ -26320,8 +26320,8 @@ Expecting one of '${allowedValues.join("', '")}'`);
26320
26320
  * @package
26321
26321
  */
26322
26322
  function useColor() {
26323
- if (process$2.env.NO_COLOR || process$2.env.FORCE_COLOR === "0" || process$2.env.FORCE_COLOR === "false") return false;
26324
- if (process$2.env.FORCE_COLOR || process$2.env.CLICOLOR_FORCE !== void 0) return true;
26323
+ if (process$3.env.NO_COLOR || process$3.env.FORCE_COLOR === "0" || process$3.env.FORCE_COLOR === "false") return false;
26324
+ if (process$3.env.FORCE_COLOR || process$3.env.CLICOLOR_FORCE !== void 0) return true;
26325
26325
  }
26326
26326
  exports.Command = Command;
26327
26327
  exports.useColor = useColor;
@@ -337600,7 +337600,7 @@ var stdio_exports = /* @__PURE__ */ __exportAll$2({
337600
337600
  function getDefaultEnvironment() {
337601
337601
  const env = {};
337602
337602
  for (const key of DEFAULT_INHERITED_ENV_VARS) {
337603
- const value = _w.env[key];
337603
+ const value = process$1.env[key];
337604
337604
  if (value === void 0) continue;
337605
337605
  if (value.startsWith("()")) continue;
337606
337606
  env[key] = value;
@@ -337611,7 +337611,7 @@ var import_cross_spawn$1, DEFAULT_INHERITED_ENV_VARS, StdioClientTransport;
337611
337611
  var init_stdio = __esmMin((() => {
337612
337612
  init_src_CeKsbNLO();
337613
337613
  import_cross_spawn$1 = /* @__PURE__ */ __toESM$2(require_cross_spawn(), 1);
337614
- DEFAULT_INHERITED_ENV_VARS = _w.platform === "win32" ? [
337614
+ DEFAULT_INHERITED_ENV_VARS = process$1.platform === "win32" ? [
337615
337615
  "APPDATA",
337616
337616
  "COMSPEC",
337617
337617
  "HOMEDRIVE",
@@ -337668,7 +337668,7 @@ var init_stdio = __esmMin((() => {
337668
337668
  this._serverParams.stderr ?? "inherit"
337669
337669
  ],
337670
337670
  shell: false,
337671
- windowsHide: _w.platform === "win32",
337671
+ windowsHide: process$1.platform === "win32",
337672
337672
  cwd: this._serverParams.cwd
337673
337673
  });
337674
337674
  this._process.on("error", (error) => {
@@ -340702,9 +340702,9 @@ const getSubprocessResult = ({ stdout }) => {
340702
340702
  //#region node_modules/.pnpm/execa@9.6.1/node_modules/execa/lib/utils/standard-stream.js
340703
340703
  const isStandardStream = (stream) => STANDARD_STREAMS.includes(stream);
340704
340704
  const STANDARD_STREAMS = [
340705
- _w.stdin,
340706
- _w.stdout,
340707
- _w.stderr
340705
+ process$1.stdin,
340706
+ process$1.stdout,
340707
+ process$1.stderr
340708
340708
  ];
340709
340709
  const STANDARD_STREAMS_ALIASES = [
340710
340710
  "stdin",
@@ -340829,9 +340829,9 @@ const NO_ESCAPE_REGEXP = /^[\w./-]+$/;
340829
340829
  //#endregion
340830
340830
  //#region node_modules/.pnpm/is-unicode-supported@2.1.0/node_modules/is-unicode-supported/index.js
340831
340831
  function isUnicodeSupported() {
340832
- const { env } = _w;
340832
+ const { env } = process$1;
340833
340833
  const { TERM, TERM_PROGRAM } = env;
340834
- if (_w.platform !== "win32") return TERM !== "linux";
340834
+ if (process$1.platform !== "win32") return TERM !== "linux";
340835
340835
  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";
340836
340836
  }
340837
340837
 
@@ -341366,7 +341366,7 @@ function traversePathUp(startPath) {
341366
341366
 
341367
341367
  //#endregion
341368
341368
  //#region node_modules/.pnpm/npm-run-path@6.0.0/node_modules/npm-run-path/index.js
341369
- const npmRunPath = ({ cwd = _w.cwd(), path: pathOption = _w.env[pathKey()], preferLocal = true, execPath = _w.execPath, addExecPath = true } = {}) => {
341369
+ const npmRunPath = ({ cwd = process$1.cwd(), path: pathOption = process$1.env[pathKey()], preferLocal = true, execPath = process$1.execPath, addExecPath = true } = {}) => {
341370
341370
  const cwdPath = path.resolve(toPath(cwd));
341371
341371
  const result = [];
341372
341372
  const pathParts = pathOption.split(path.delimiter);
@@ -341384,7 +341384,7 @@ const applyExecPath = (result, pathParts, execPath, cwdPath) => {
341384
341384
  const pathPart = path.resolve(cwdPath, toPath(execPath), "..");
341385
341385
  if (!pathParts.includes(pathPart)) result.push(pathPart);
341386
341386
  };
341387
- const npmRunPathEnv = ({ env = _w.env, ...options } = {}) => {
341387
+ const npmRunPathEnv = ({ env = process$1.env, ...options } = {}) => {
341388
341388
  env = { ...env };
341389
341389
  const pathName = pathKey({ env });
341390
341390
  options.path = env[pathName];
@@ -342519,7 +342519,7 @@ const normalizeCwd = (cwd = getDefaultCwd()) => {
342519
342519
  };
342520
342520
  const getDefaultCwd = () => {
342521
342521
  try {
342522
- return _w.cwd();
342522
+ return process$1.cwd();
342523
342523
  } catch (error) {
342524
342524
  error.message = `The current directory does not exist.\n${error.message}`;
342525
342525
  throw error;
@@ -342555,7 +342555,7 @@ const normalizeOptions = (filePath, rawArguments, rawOptions) => {
342555
342555
  options.killSignal = normalizeKillSignal(options.killSignal);
342556
342556
  options.forceKillAfterDelay = normalizeForceKillAfterDelay(options.forceKillAfterDelay);
342557
342557
  options.lines = options.lines.map((lines, fdNumber) => lines && !BINARY_ENCODINGS.has(options.encoding) && options.buffer[fdNumber]);
342558
- if (_w.platform === "win32" && path.basename(file, ".exe") === "cmd") commandArguments.unshift("/q");
342558
+ if (process$1.platform === "win32" && path.basename(file, ".exe") === "cmd") commandArguments.unshift("/q");
342559
342559
  return {
342560
342560
  file,
342561
342561
  commandArguments,
@@ -342582,7 +342582,7 @@ const addDefaultOptions = ({ extendEnv = true, preferLocal = false, cwd, localDi
342582
342582
  });
342583
342583
  const getEnv = ({ env: envOption, extendEnv, preferLocal, node, localDirectory, nodePath }) => {
342584
342584
  const env = extendEnv ? {
342585
- ..._w.env,
342585
+ ...process$1.env,
342586
342586
  ...envOption
342587
342587
  } : envOption;
342588
342588
  if (preferLocal || node) return npmRunPathEnv({
@@ -343584,12 +343584,12 @@ const guessStreamDirection = {
343584
343584
  }
343585
343585
  };
343586
343586
  const getStandardStreamDirection = (value) => {
343587
- if ([0, _w.stdin].includes(value)) return "input";
343587
+ if ([0, process$1.stdin].includes(value)) return "input";
343588
343588
  if ([
343589
343589
  1,
343590
343590
  2,
343591
- _w.stdout,
343592
- _w.stderr
343591
+ process$1.stdout,
343592
+ process$1.stderr
343593
343593
  ].includes(value)) return "output";
343594
343594
  };
343595
343595
  const DEFAULT_DIRECTION = "output";
@@ -344653,9 +344653,9 @@ const addIpcMethods = (subprocess, { ipc }) => {
344653
344653
  Object.assign(subprocess, getIpcMethods(subprocess, false, ipc));
344654
344654
  };
344655
344655
  const getIpcExport = () => {
344656
- const anyProcess = _w;
344656
+ const anyProcess = process$1;
344657
344657
  const isSubprocess = true;
344658
- const ipc = _w.channel !== void 0;
344658
+ const ipc = process$1.channel !== void 0;
344659
344659
  return {
344660
344660
  ...getIpcMethods(anyProcess, isSubprocess, ipc),
344661
344661
  getCancelSignal: getCancelSignal$1.bind(void 0, {
@@ -345132,7 +345132,7 @@ var SignalExitFallback = class extends SignalExitBase {
345132
345132
  };
345133
345133
  var SignalExit = class extends SignalExitBase {
345134
345134
  /* c8 ignore start */
345135
- #hupSig = process$1.platform === "win32" ? "SIGINT" : "SIGHUP";
345135
+ #hupSig = process$2.platform === "win32" ? "SIGINT" : "SIGHUP";
345136
345136
  /* c8 ignore stop */
345137
345137
  #emitter = new Emitter();
345138
345138
  #process;
@@ -345227,8 +345227,8 @@ var SignalExit = class extends SignalExitBase {
345227
345227
  } else return og.call(this.#process, ev, ...args);
345228
345228
  }
345229
345229
  };
345230
- const process$1 = globalThis.process;
345231
- const { onExit, load: load$1, unload } = signalExitWrap(processOk(process$1) ? new SignalExit(process$1) : new SignalExitFallback());
345230
+ const process$2 = globalThis.process;
345231
+ const { onExit, load: load$1, unload } = signalExitWrap(processOk(process$2) ? new SignalExit(process$2) : new SignalExitFallback());
345232
345232
 
345233
345233
  //#endregion
345234
345234
  //#region node_modules/.pnpm/execa@9.6.1/node_modules/execa/lib/terminate/cleanup.js
package/man/man1/lh.1 CHANGED
@@ -1,6 +1,6 @@
1
1
  .\" Code generated by `npm run man:generate`; DO NOT EDIT.
2
2
  .\" Manual command details come from the Commander command tree.
3
- .TH LH 1 "" "@lobehub/cli 0.0.210" "User Commands"
3
+ .TH LH 1 "" "@lobehub/cli 0.0.211" "User Commands"
4
4
  .SH NAME
5
5
  lh \- LobeHub CLI \- manage and connect to LobeHub services
6
6
  .SH SYNOPSIS
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lobehub/cli",
3
- "version": "0.0.210",
3
+ "version": "0.0.211",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "https://github.com/lobehub/lobehub",
@@ -83,5 +83,5 @@
83
83
  "access": "public",
84
84
  "registry": "https://registry.npmjs.org"
85
85
  },
86
- "gitHead": "39e8a1df81ce900d25d5766d5a7180d755a753e2"
86
+ "gitHead": "f44156f396374e944f83892173f444632c5b02fc"
87
87
  }