@jixo/cli 0.27.0 → 4.0.0

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.
@@ -1673,9 +1673,9 @@ var require_fs$3 = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/fast-g
1673
1673
  //#region ../../node_modules/.pnpm/fast-glob@3.3.3/node_modules/fast-glob/out/utils/path.js
1674
1674
  var require_path = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/fast-glob@3.3.3/node_modules/fast-glob/out/utils/path.js": ((exports) => {
1675
1675
  Object.defineProperty(exports, "__esModule", { value: true });
1676
- const os$1 = __require("os");
1676
+ const os$2 = __require("os");
1677
1677
  const path$10 = __require("path");
1678
- const IS_WINDOWS_PLATFORM = os$1.platform() === "win32";
1678
+ const IS_WINDOWS_PLATFORM = os$2.platform() === "win32";
1679
1679
  const LEADING_DOT_SEGMENT_CHARACTERS_COUNT = 2;
1680
1680
  /**
1681
1681
  * All non-escaped special characters.
@@ -7031,12 +7031,12 @@ var require_sync = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/fast-g
7031
7031
  var require_settings = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/fast-glob@3.3.3/node_modules/fast-glob/out/settings.js": ((exports) => {
7032
7032
  Object.defineProperty(exports, "__esModule", { value: true });
7033
7033
  const fs$2 = __require("fs");
7034
- const os = __require("os");
7034
+ const os$1 = __require("os");
7035
7035
  /**
7036
7036
  * The `os.cpus` method can return zero. We expect the number of cores to be greater than zero.
7037
7037
  * https://github.com/nodejs/node/blob/7faeddf23a98c53896f8b574a6e66589e8fb1eb8/lib/os.js#L106-L107
7038
7038
  */
7039
- const CPU_COUNT = Math.max(os.cpus().length, 1);
7039
+ const CPU_COUNT = Math.max(os$1.cpus().length, 1);
7040
7040
  exports.DEFAULT_FILE_SYSTEM_ADAPTER = {
7041
7041
  lstat: fs$2.lstat,
7042
7042
  lstatSync: fs$2.lstatSync,
@@ -7593,7 +7593,7 @@ var require_common = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/debu
7593
7593
  * This is the common logic for both the Node.js and web browser
7594
7594
  * implementations of `debug()`.
7595
7595
  */
7596
- function setup(env) {
7596
+ function setup(env$1) {
7597
7597
  createDebug.debug = createDebug;
7598
7598
  createDebug.default = createDebug;
7599
7599
  createDebug.coerce = coerce;
@@ -7602,8 +7602,8 @@ var require_common = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/debu
7602
7602
  createDebug.enabled = enabled;
7603
7603
  createDebug.humanize = require_ms();
7604
7604
  createDebug.destroy = destroy;
7605
- Object.keys(env).forEach((key) => {
7606
- createDebug[key] = env[key];
7605
+ Object.keys(env$1).forEach((key) => {
7606
+ createDebug[key] = env$1[key];
7607
7607
  });
7608
7608
  /**
7609
7609
  * The currently active debug mode names, and names to skip.
@@ -7986,6 +7986,87 @@ var require_browser = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/deb
7986
7986
  };
7987
7987
  }) });
7988
7988
 
7989
+ //#endregion
7990
+ //#region ../../node_modules/.pnpm/has-flag@4.0.0/node_modules/has-flag/index.js
7991
+ var require_has_flag = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/has-flag@4.0.0/node_modules/has-flag/index.js": ((exports, module) => {
7992
+ module.exports = (flag, argv = process.argv) => {
7993
+ const prefix = flag.startsWith("-") ? "" : flag.length === 1 ? "-" : "--";
7994
+ const position = argv.indexOf(prefix + flag);
7995
+ const terminatorPosition = argv.indexOf("--");
7996
+ return position !== -1 && (terminatorPosition === -1 || position < terminatorPosition);
7997
+ };
7998
+ }) });
7999
+
8000
+ //#endregion
8001
+ //#region ../../node_modules/.pnpm/supports-color@7.2.0/node_modules/supports-color/index.js
8002
+ var require_supports_color = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/supports-color@7.2.0/node_modules/supports-color/index.js": ((exports, module) => {
8003
+ const os = __require("os");
8004
+ const tty$1 = __require("tty");
8005
+ const hasFlag = require_has_flag();
8006
+ const { env } = process;
8007
+ let forceColor;
8008
+ if (hasFlag("no-color") || hasFlag("no-colors") || hasFlag("color=false") || hasFlag("color=never")) forceColor = 0;
8009
+ else if (hasFlag("color") || hasFlag("colors") || hasFlag("color=true") || hasFlag("color=always")) forceColor = 1;
8010
+ if ("FORCE_COLOR" in env) if (env.FORCE_COLOR === "true") forceColor = 1;
8011
+ else if (env.FORCE_COLOR === "false") forceColor = 0;
8012
+ else forceColor = env.FORCE_COLOR.length === 0 ? 1 : Math.min(parseInt(env.FORCE_COLOR, 10), 3);
8013
+ function translateLevel(level) {
8014
+ if (level === 0) return false;
8015
+ return {
8016
+ level,
8017
+ hasBasic: true,
8018
+ has256: level >= 2,
8019
+ has16m: level >= 3
8020
+ };
8021
+ }
8022
+ function supportsColor(haveStream, streamIsTTY) {
8023
+ if (forceColor === 0) return 0;
8024
+ if (hasFlag("color=16m") || hasFlag("color=full") || hasFlag("color=truecolor")) return 3;
8025
+ if (hasFlag("color=256")) return 2;
8026
+ if (haveStream && !streamIsTTY && forceColor === void 0) return 0;
8027
+ const min = forceColor || 0;
8028
+ if (env.TERM === "dumb") return min;
8029
+ if (process.platform === "win32") {
8030
+ const osRelease = os.release().split(".");
8031
+ if (Number(osRelease[0]) >= 10 && Number(osRelease[2]) >= 10586) return Number(osRelease[2]) >= 14931 ? 3 : 2;
8032
+ return 1;
8033
+ }
8034
+ if ("CI" in env) {
8035
+ if ([
8036
+ "TRAVIS",
8037
+ "CIRCLECI",
8038
+ "APPVEYOR",
8039
+ "GITLAB_CI",
8040
+ "GITHUB_ACTIONS",
8041
+ "BUILDKITE"
8042
+ ].some((sign) => sign in env) || env.CI_NAME === "codeship") return 1;
8043
+ return min;
8044
+ }
8045
+ if ("TEAMCITY_VERSION" in env) return /^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.test(env.TEAMCITY_VERSION) ? 1 : 0;
8046
+ if (env.COLORTERM === "truecolor") return 3;
8047
+ if ("TERM_PROGRAM" in env) {
8048
+ const version$1 = parseInt((env.TERM_PROGRAM_VERSION || "").split(".")[0], 10);
8049
+ switch (env.TERM_PROGRAM) {
8050
+ case "iTerm.app": return version$1 >= 3 ? 3 : 2;
8051
+ case "Apple_Terminal": return 2;
8052
+ }
8053
+ }
8054
+ if (/-256(color)?$/i.test(env.TERM)) return 2;
8055
+ if (/^screen|^xterm|^vt100|^vt220|^rxvt|color|ansi|cygwin|linux/i.test(env.TERM)) return 1;
8056
+ if ("COLORTERM" in env) return 1;
8057
+ return min;
8058
+ }
8059
+ function getSupportLevel(stream$1) {
8060
+ const level = supportsColor(stream$1, stream$1 && stream$1.isTTY);
8061
+ return translateLevel(level);
8062
+ }
8063
+ module.exports = {
8064
+ supportsColor: getSupportLevel,
8065
+ stdout: translateLevel(supportsColor(true, tty$1.isatty(1))),
8066
+ stderr: translateLevel(supportsColor(true, tty$1.isatty(2)))
8067
+ };
8068
+ }) });
8069
+
7989
8070
  //#endregion
7990
8071
  //#region ../../node_modules/.pnpm/debug@4.4.1/node_modules/debug/src/node.js
7991
8072
  var require_node = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/debug@4.4.1/node_modules/debug/src/node.js": ((exports, module) => {
@@ -8016,8 +8097,8 @@ var require_node = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/debug@
8016
8097
  1
8017
8098
  ];
8018
8099
  try {
8019
- const supportsColor = __require("supports-color");
8020
- if (supportsColor && (supportsColor.stderr || supportsColor).level >= 2) exports.colors = [
8100
+ const supportsColor$1 = require_supports_color();
8101
+ if (supportsColor$1 && (supportsColor$1.stderr || supportsColor$1).level >= 2) exports.colors = [
8021
8102
  20,
8022
8103
  21,
8023
8104
  26,
@@ -19751,7 +19832,7 @@ const jixoProvider = async (specifier, options) => {
19751
19832
  if (specifier === "code_name") return options.codeName;
19752
19833
  if (specifier === "datetime") return (/* @__PURE__ */ new Date()).toLocaleString();
19753
19834
  if (specifier === "memory") {
19754
- const { localFileReplacement: localFileReplacement$1 } = await import("./file-replacer-DY3KYbf9.js");
19835
+ const { localFileReplacement: localFileReplacement$1 } = await import("./file-replacer-ajVzZOp7.js");
19755
19836
  const memoryOptions = {
19756
19837
  ...options,
19757
19838
  globOrFilepath: `.jixo/memory/${options.codeName}/*.md`,
@@ -19766,12 +19847,12 @@ const jixoProvider = async (specifier, options) => {
19766
19847
  let content = (await GET_JIXO_PROMPT())[specifier];
19767
19848
  if (/\.(json|ts)$/.test(specifier)) content = JSON.stringify(content, null, zod_default.int().optional().safeParse(options.params.spaces).data ?? 2);
19768
19849
  else {
19769
- const { _gen_content } = await import("./gen-prompt-Dzy9yRhQ.js");
19850
+ const { _gen_content } = await import("./gen-prompt-DF1HOjXb.js");
19770
19851
  if (!content) throw new Error(`No found jixo specifier: ${specifier}`);
19771
19852
  content = await _gen_content(options.codeName, content, options.rootResolver);
19772
19853
  }
19773
19854
  if (content) {
19774
- const { useFileOrInject: useFileOrInject$1 } = await import("./file-replacer-DY3KYbf9.js");
19855
+ const { useFileOrInject: useFileOrInject$1 } = await import("./file-replacer-ajVzZOp7.js");
19775
19856
  return useFileOrInject$1(options.mode, `${specifier}.md`, content, options.params);
19776
19857
  }
19777
19858
  return `<!-- unknown jixo content ${specifier} -->`;
@@ -19916,5 +19997,5 @@ const localFileReplacement = async (options) => {
19916
19997
  };
19917
19998
 
19918
19999
  //#endregion
19919
- export { $ZodAny, $ZodArray, $ZodBoolean, $ZodCustom, $ZodLiteral, $ZodNumber, $ZodObject, $ZodOptional, $ZodString, $ZodType, $ZodUnion, $ZodUnknown, $constructor, N, __commonJS, __export, __require, __toESM, _any, _boolean, _custom, _enum, _number, _string, _unknown, array, assignProp, boolean$1 as boolean, clone, createAcontext, createResolver, createResolverByRootFile, defaultParseSearch, defineLazy, delay, extend, func_catch, func_parallel_limit, func_remember, globFilesWithParams, globbySync, handleFileReplacement, isDynamicPattern, iter_map_not_null, literal, localFileReplacement, map_get_or_put, map_get_or_put_async, normalizeFilePath, normalizeParams, number$1 as number, obj_assign_props, object, parse$1 as parse, parseAsync$1 as parseAsync, partial, reactiveFs, require_micromatch, require_src, safeParse$1 as safeParse, safeParseAsync$1 as safeParseAsync, string$1 as string, timmers, toJSONSchema, toPath, traversePathUp, union, useFileOrInject, z, zod_default };
19920
- //# sourceMappingURL=file-replacer-D6j8Nj7r.js.map
20000
+ export { $ZodAny, $ZodArray, $ZodBoolean, $ZodCustom, $ZodDiscriminatedUnion, $ZodLiteral, $ZodNumber, $ZodObject, $ZodOptional, $ZodString, $ZodType, $ZodUnion, $ZodUnknown, $constructor, N, __commonJS, __export, __require, __toESM, _any, _boolean, _custom, _enum, _number, _string, _unknown, array, assignProp, boolean$1 as boolean, clone, createAcontext, createResolver, createResolverByRootFile, defaultParseSearch, defineLazy, delay, extend, func_catch, func_parallel_limit, func_remember, globFilesWithParams, globbySync, handleFileReplacement, isDynamicPattern, iter_map_not_null, literal, localFileReplacement, map_get_or_put, map_get_or_put_async, normalizeFilePath, normalizeParams, number$1 as number, obj_assign_props, object, parse$1 as parse, parseAsync$1 as parseAsync, partial, reactiveFs, require_micromatch, require_src, safeParse$1 as safeParse, safeParseAsync$1 as safeParseAsync, string$1 as string, timmers, toJSONSchema, toPath, traversePathUp, union, useFileOrInject, z, zod_default };
20001
+ //# sourceMappingURL=file-replacer-C3H2FqOL.js.map