@lobehub/cli 0.0.146 → 0.0.148

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";
@@ -9824,6 +9824,7 @@ var init_fetch = __esmMin((() => {
9824
9824
  WorkspaceSubscriptionInactive: "WorkspaceSubscriptionInactive",
9825
9825
  ShareMessageLimitExceeded: "ShareMessageLimitExceeded",
9826
9826
  ShareSpendLimitExceeded: "ShareSpendLimitExceeded",
9827
+ SharePromptTooLong: "SharePromptTooLong",
9827
9828
  ShareHeterogeneousAgentUnsupported: "ShareHeterogeneousAgentUnsupported",
9828
9829
  ShareHeteroDeviceUnavailable: "ShareHeteroDeviceUnavailable",
9829
9830
  AgentShareProviderNotSupported: "AgentShareProviderNotSupported",
@@ -21955,7 +21956,7 @@ var require_command = /* @__PURE__ */ __commonJSMin$2(((exports) => {
21955
21956
  const childProcess$2 = __require("node:child_process");
21956
21957
  const path$16 = __require("node:path");
21957
21958
  const fs$17 = __require("node:fs");
21958
- const process$2 = __require("node:process");
21959
+ const process$3 = __require("node:process");
21959
21960
  const { Argument, humanReadableArgName } = require_argument();
21960
21961
  const { CommanderError } = require_error$1();
21961
21962
  const { Help, stripColor } = require_help();
@@ -22007,13 +22008,13 @@ var require_command = /* @__PURE__ */ __commonJSMin$2(((exports) => {
22007
22008
  this._showSuggestionAfterError = true;
22008
22009
  this._savedState = null;
22009
22010
  this._outputConfiguration = {
22010
- writeOut: (str) => process$2.stdout.write(str),
22011
- writeErr: (str) => process$2.stderr.write(str),
22011
+ writeOut: (str) => process$3.stdout.write(str),
22012
+ writeErr: (str) => process$3.stderr.write(str),
22012
22013
  outputError: (str, write) => write(str),
22013
- getOutHelpWidth: () => process$2.stdout.isTTY ? process$2.stdout.columns : void 0,
22014
- getErrHelpWidth: () => process$2.stderr.isTTY ? process$2.stderr.columns : void 0,
22015
- getOutHasColors: () => useColor() ?? (process$2.stdout.isTTY && process$2.stdout.hasColors?.()),
22016
- getErrHasColors: () => useColor() ?? (process$2.stderr.isTTY && process$2.stderr.hasColors?.()),
22014
+ getOutHelpWidth: () => process$3.stdout.isTTY ? process$3.stdout.columns : void 0,
22015
+ getErrHelpWidth: () => process$3.stderr.isTTY ? process$3.stderr.columns : void 0,
22016
+ getOutHasColors: () => useColor() ?? (process$3.stdout.isTTY && process$3.stdout.hasColors?.()),
22017
+ getErrHasColors: () => useColor() ?? (process$3.stderr.isTTY && process$3.stderr.hasColors?.()),
22017
22018
  stripColor: (str) => stripColor(str)
22018
22019
  };
22019
22020
  this._hidden = false;
@@ -22371,7 +22372,7 @@ Expecting one of '${allowedValues.join("', '")}'`);
22371
22372
  */
22372
22373
  _exit(exitCode, code, message) {
22373
22374
  if (this._exitCallback) this._exitCallback(new CommanderError(exitCode, code, message));
22374
- process$2.exit(exitCode);
22375
+ process$3.exit(exitCode);
22375
22376
  }
22376
22377
  /**
22377
22378
  * Register callback `fn` for the command.
@@ -22710,11 +22711,11 @@ Expecting one of '${allowedValues.join("', '")}'`);
22710
22711
  if (argv !== void 0 && !Array.isArray(argv)) throw new Error("first parameter to parse must be array or undefined");
22711
22712
  parseOptions = parseOptions || {};
22712
22713
  if (argv === void 0 && parseOptions.from === void 0) {
22713
- if (process$2.versions?.electron) parseOptions.from = "electron";
22714
- const execArgv = process$2.execArgv ?? [];
22714
+ if (process$3.versions?.electron) parseOptions.from = "electron";
22715
+ const execArgv = process$3.execArgv ?? [];
22715
22716
  if (execArgv.includes("-e") || execArgv.includes("--eval") || execArgv.includes("-p") || execArgv.includes("--print")) parseOptions.from = "eval";
22716
22717
  }
22717
- if (argv === void 0) argv = process$2.argv;
22718
+ if (argv === void 0) argv = process$3.argv;
22718
22719
  this.rawArgs = argv.slice();
22719
22720
  let userArgs;
22720
22721
  switch (parseOptions.from) {
@@ -22724,7 +22725,7 @@ Expecting one of '${allowedValues.join("', '")}'`);
22724
22725
  userArgs = argv.slice(2);
22725
22726
  break;
22726
22727
  case "electron":
22727
- if (process$2.defaultApp) {
22728
+ if (process$3.defaultApp) {
22728
22729
  this._scriptPath = argv[1];
22729
22730
  userArgs = argv.slice(2);
22730
22731
  } else userArgs = argv.slice(1);
@@ -22889,16 +22890,16 @@ Expecting one of '${allowedValues.join("', '")}'`);
22889
22890
  }
22890
22891
  launchWithNode = sourceExt.includes(path$16.extname(executableFile));
22891
22892
  let proc;
22892
- if (process$2.platform !== "win32") if (launchWithNode) {
22893
+ if (process$3.platform !== "win32") if (launchWithNode) {
22893
22894
  args.unshift(executableFile);
22894
- args = incrementNodeInspectorPort(process$2.execArgv).concat(args);
22895
- proc = childProcess$2.spawn(process$2.argv[0], args, { stdio: "inherit" });
22895
+ args = incrementNodeInspectorPort(process$3.execArgv).concat(args);
22896
+ proc = childProcess$2.spawn(process$3.argv[0], args, { stdio: "inherit" });
22896
22897
  } else proc = childProcess$2.spawn(executableFile, args, { stdio: "inherit" });
22897
22898
  else {
22898
22899
  this._checkForMissingExecutable(executableFile, executableDir, subcommand._name);
22899
22900
  args.unshift(executableFile);
22900
- args = incrementNodeInspectorPort(process$2.execArgv).concat(args);
22901
- proc = childProcess$2.spawn(process$2.execPath, args, { stdio: "inherit" });
22901
+ args = incrementNodeInspectorPort(process$3.execArgv).concat(args);
22902
+ proc = childProcess$2.spawn(process$3.execPath, args, { stdio: "inherit" });
22902
22903
  }
22903
22904
  if (!proc.killed) [
22904
22905
  "SIGUSR1",
@@ -22907,20 +22908,20 @@ Expecting one of '${allowedValues.join("', '")}'`);
22907
22908
  "SIGINT",
22908
22909
  "SIGHUP"
22909
22910
  ].forEach((signal) => {
22910
- process$2.on(signal, () => {
22911
+ process$3.on(signal, () => {
22911
22912
  if (proc.killed === false && proc.exitCode === null) proc.kill(signal);
22912
22913
  });
22913
22914
  });
22914
22915
  const exitCallback = this._exitCallback;
22915
22916
  proc.on("close", (code) => {
22916
22917
  code = code ?? 1;
22917
- if (!exitCallback) process$2.exit(code);
22918
+ if (!exitCallback) process$3.exit(code);
22918
22919
  else exitCallback(new CommanderError(code, "commander.executeSubCommandAsync", "(close)"));
22919
22920
  });
22920
22921
  proc.on("error", (err) => {
22921
22922
  if (err.code === "ENOENT") this._checkForMissingExecutable(executableFile, executableDir, subcommand._name);
22922
22923
  else if (err.code === "EACCES") throw new Error(`'${executableFile}' not executable`);
22923
- if (!exitCallback) process$2.exit(1);
22924
+ if (!exitCallback) process$3.exit(1);
22924
22925
  else {
22925
22926
  const wrappedError = new CommanderError(1, "commander.executeSubCommandAsync", "(error)");
22926
22927
  wrappedError.nestedError = err;
@@ -23329,13 +23330,13 @@ Expecting one of '${allowedValues.join("', '")}'`);
23329
23330
  */
23330
23331
  _parseOptionsEnv() {
23331
23332
  this.options.forEach((option) => {
23332
- if (option.envVar && option.envVar in process$2.env) {
23333
+ if (option.envVar && option.envVar in process$3.env) {
23333
23334
  const optionKey = option.attributeName();
23334
23335
  if (this.getOptionValue(optionKey) === void 0 || [
23335
23336
  "default",
23336
23337
  "config",
23337
23338
  "env"
23338
- ].includes(this.getOptionValueSource(optionKey))) if (option.required || option.optional) this.emit(`optionEnv:${option.name()}`, process$2.env[option.envVar]);
23339
+ ].includes(this.getOptionValueSource(optionKey))) if (option.required || option.optional) this.emit(`optionEnv:${option.name()}`, process$3.env[option.envVar]);
23339
23340
  else this.emit(`optionEnv:${option.name()}`);
23340
23341
  }
23341
23342
  });
@@ -23752,7 +23753,7 @@ Expecting one of '${allowedValues.join("', '")}'`);
23752
23753
  */
23753
23754
  help(contextOptions) {
23754
23755
  this.outputHelp(contextOptions);
23755
- let exitCode = Number(process$2.exitCode ?? 0);
23756
+ let exitCode = Number(process$3.exitCode ?? 0);
23756
23757
  if (exitCode === 0 && contextOptions && typeof contextOptions !== "function" && contextOptions.error) exitCode = 1;
23757
23758
  this._exit(exitCode, "commander.help", "(outputHelp)");
23758
23759
  }
@@ -23842,8 +23843,8 @@ Expecting one of '${allowedValues.join("', '")}'`);
23842
23843
  * @package
23843
23844
  */
23844
23845
  function useColor() {
23845
- if (process$2.env.NO_COLOR || process$2.env.FORCE_COLOR === "0" || process$2.env.FORCE_COLOR === "false") return false;
23846
- if (process$2.env.FORCE_COLOR || process$2.env.CLICOLOR_FORCE !== void 0) return true;
23846
+ if (process$3.env.NO_COLOR || process$3.env.FORCE_COLOR === "0" || process$3.env.FORCE_COLOR === "false") return false;
23847
+ if (process$3.env.FORCE_COLOR || process$3.env.CLICOLOR_FORCE !== void 0) return true;
23847
23848
  }
23848
23849
  exports.Command = Command;
23849
23850
  exports.useColor = useColor;
@@ -333027,7 +333028,7 @@ var stdio_exports = /* @__PURE__ */ __exportAll$2({
333027
333028
  function getDefaultEnvironment() {
333028
333029
  const env = {};
333029
333030
  for (const key of DEFAULT_INHERITED_ENV_VARS) {
333030
- const value = _w.env[key];
333031
+ const value = process$1.env[key];
333031
333032
  if (value === void 0) continue;
333032
333033
  if (value.startsWith("()")) continue;
333033
333034
  env[key] = value;
@@ -333038,7 +333039,7 @@ var import_cross_spawn$1, DEFAULT_INHERITED_ENV_VARS, StdioClientTransport;
333038
333039
  var init_stdio = __esmMin((() => {
333039
333040
  init_src_CeKsbNLO();
333040
333041
  import_cross_spawn$1 = /* @__PURE__ */ __toESM$2(require_cross_spawn(), 1);
333041
- DEFAULT_INHERITED_ENV_VARS = _w.platform === "win32" ? [
333042
+ DEFAULT_INHERITED_ENV_VARS = process$1.platform === "win32" ? [
333042
333043
  "APPDATA",
333043
333044
  "COMSPEC",
333044
333045
  "HOMEDRIVE",
@@ -333095,7 +333096,7 @@ var init_stdio = __esmMin((() => {
333095
333096
  this._serverParams.stderr ?? "inherit"
333096
333097
  ],
333097
333098
  shell: false,
333098
- windowsHide: _w.platform === "win32",
333099
+ windowsHide: process$1.platform === "win32",
333099
333100
  cwd: this._serverParams.cwd
333100
333101
  });
333101
333102
  this._process.on("error", (error) => {
@@ -336129,9 +336130,9 @@ const getSubprocessResult = ({ stdout }) => {
336129
336130
  //#region node_modules/.pnpm/execa@9.6.1/node_modules/execa/lib/utils/standard-stream.js
336130
336131
  const isStandardStream = (stream) => STANDARD_STREAMS.includes(stream);
336131
336132
  const STANDARD_STREAMS = [
336132
- _w.stdin,
336133
- _w.stdout,
336134
- _w.stderr
336133
+ process$1.stdin,
336134
+ process$1.stdout,
336135
+ process$1.stderr
336135
336136
  ];
336136
336137
  const STANDARD_STREAMS_ALIASES = [
336137
336138
  "stdin",
@@ -336256,9 +336257,9 @@ const NO_ESCAPE_REGEXP = /^[\w./-]+$/;
336256
336257
  //#endregion
336257
336258
  //#region node_modules/.pnpm/is-unicode-supported@2.1.0/node_modules/is-unicode-supported/index.js
336258
336259
  function isUnicodeSupported() {
336259
- const { env } = _w;
336260
+ const { env } = process$1;
336260
336261
  const { TERM, TERM_PROGRAM } = env;
336261
- if (_w.platform !== "win32") return TERM !== "linux";
336262
+ if (process$1.platform !== "win32") return TERM !== "linux";
336262
336263
  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";
336263
336264
  }
336264
336265
 
@@ -336793,7 +336794,7 @@ function traversePathUp(startPath) {
336793
336794
 
336794
336795
  //#endregion
336795
336796
  //#region node_modules/.pnpm/npm-run-path@6.0.0/node_modules/npm-run-path/index.js
336796
- const npmRunPath = ({ cwd = _w.cwd(), path: pathOption = _w.env[pathKey()], preferLocal = true, execPath = _w.execPath, addExecPath = true } = {}) => {
336797
+ const npmRunPath = ({ cwd = process$1.cwd(), path: pathOption = process$1.env[pathKey()], preferLocal = true, execPath = process$1.execPath, addExecPath = true } = {}) => {
336797
336798
  const cwdPath = path.resolve(toPath(cwd));
336798
336799
  const result = [];
336799
336800
  const pathParts = pathOption.split(path.delimiter);
@@ -336811,7 +336812,7 @@ const applyExecPath = (result, pathParts, execPath, cwdPath) => {
336811
336812
  const pathPart = path.resolve(cwdPath, toPath(execPath), "..");
336812
336813
  if (!pathParts.includes(pathPart)) result.push(pathPart);
336813
336814
  };
336814
- const npmRunPathEnv = ({ env = _w.env, ...options } = {}) => {
336815
+ const npmRunPathEnv = ({ env = process$1.env, ...options } = {}) => {
336815
336816
  env = { ...env };
336816
336817
  const pathName = pathKey({ env });
336817
336818
  options.path = env[pathName];
@@ -337946,7 +337947,7 @@ const normalizeCwd = (cwd = getDefaultCwd()) => {
337946
337947
  };
337947
337948
  const getDefaultCwd = () => {
337948
337949
  try {
337949
- return _w.cwd();
337950
+ return process$1.cwd();
337950
337951
  } catch (error) {
337951
337952
  error.message = `The current directory does not exist.\n${error.message}`;
337952
337953
  throw error;
@@ -337982,7 +337983,7 @@ const normalizeOptions = (filePath, rawArguments, rawOptions) => {
337982
337983
  options.killSignal = normalizeKillSignal(options.killSignal);
337983
337984
  options.forceKillAfterDelay = normalizeForceKillAfterDelay(options.forceKillAfterDelay);
337984
337985
  options.lines = options.lines.map((lines, fdNumber) => lines && !BINARY_ENCODINGS.has(options.encoding) && options.buffer[fdNumber]);
337985
- if (_w.platform === "win32" && path.basename(file, ".exe") === "cmd") commandArguments.unshift("/q");
337986
+ if (process$1.platform === "win32" && path.basename(file, ".exe") === "cmd") commandArguments.unshift("/q");
337986
337987
  return {
337987
337988
  file,
337988
337989
  commandArguments,
@@ -338009,7 +338010,7 @@ const addDefaultOptions = ({ extendEnv = true, preferLocal = false, cwd, localDi
338009
338010
  });
338010
338011
  const getEnv = ({ env: envOption, extendEnv, preferLocal, node, localDirectory, nodePath }) => {
338011
338012
  const env = extendEnv ? {
338012
- ..._w.env,
338013
+ ...process$1.env,
338013
338014
  ...envOption
338014
338015
  } : envOption;
338015
338016
  if (preferLocal || node) return npmRunPathEnv({
@@ -339011,12 +339012,12 @@ const guessStreamDirection = {
339011
339012
  }
339012
339013
  };
339013
339014
  const getStandardStreamDirection = (value) => {
339014
- if ([0, _w.stdin].includes(value)) return "input";
339015
+ if ([0, process$1.stdin].includes(value)) return "input";
339015
339016
  if ([
339016
339017
  1,
339017
339018
  2,
339018
- _w.stdout,
339019
- _w.stderr
339019
+ process$1.stdout,
339020
+ process$1.stderr
339020
339021
  ].includes(value)) return "output";
339021
339022
  };
339022
339023
  const DEFAULT_DIRECTION = "output";
@@ -340080,9 +340081,9 @@ const addIpcMethods = (subprocess, { ipc }) => {
340080
340081
  Object.assign(subprocess, getIpcMethods(subprocess, false, ipc));
340081
340082
  };
340082
340083
  const getIpcExport = () => {
340083
- const anyProcess = _w;
340084
+ const anyProcess = process$1;
340084
340085
  const isSubprocess = true;
340085
- const ipc = _w.channel !== void 0;
340086
+ const ipc = process$1.channel !== void 0;
340086
340087
  return {
340087
340088
  ...getIpcMethods(anyProcess, isSubprocess, ipc),
340088
340089
  getCancelSignal: getCancelSignal$1.bind(void 0, {
@@ -340559,7 +340560,7 @@ var SignalExitFallback = class extends SignalExitBase {
340559
340560
  };
340560
340561
  var SignalExit = class extends SignalExitBase {
340561
340562
  /* c8 ignore start */
340562
- #hupSig = process$1.platform === "win32" ? "SIGINT" : "SIGHUP";
340563
+ #hupSig = process$2.platform === "win32" ? "SIGINT" : "SIGHUP";
340563
340564
  /* c8 ignore stop */
340564
340565
  #emitter = new Emitter();
340565
340566
  #process;
@@ -340654,8 +340655,8 @@ var SignalExit = class extends SignalExitBase {
340654
340655
  } else return og.call(this.#process, ev, ...args);
340655
340656
  }
340656
340657
  };
340657
- const process$1 = globalThis.process;
340658
- const { onExit, load: load$1, unload } = signalExitWrap(processOk(process$1) ? new SignalExit(process$1) : new SignalExitFallback());
340658
+ const process$2 = globalThis.process;
340659
+ const { onExit, load: load$1, unload } = signalExitWrap(processOk(process$2) ? new SignalExit(process$2) : new SignalExitFallback());
340659
340660
 
340660
340661
  //#endregion
340661
340662
  //#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.146" "User Commands"
3
+ .TH LH 1 "" "@lobehub/cli 0.0.148" "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.146",
3
+ "version": "0.0.148",
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": "43358e80057fa455ecc6b02ddf2263276a70c0a2"
86
+ "gitHead": "49f73191c5af2987738f96ffe558541026770fa5"
87
87
  }