@ariestools/toolchain 9.0.1 → 9.0.2

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 (31) hide show
  1. package/dist/actions/enable/editXyConfigCompile.d.ts +32 -0
  2. package/dist/actions/enable/editXyConfigCompile.d.ts.map +1 -0
  3. package/dist/actions/enable/index.d.ts +3 -0
  4. package/dist/actions/enable/index.d.ts.map +1 -0
  5. package/dist/actions/enable/tsNative.d.ts +36 -0
  6. package/dist/actions/enable/tsNative.d.ts.map +1 -0
  7. package/dist/actions/index.d.ts +1 -0
  8. package/dist/actions/index.d.ts.map +1 -1
  9. package/dist/actions/package/compile/XyConfig.d.ts +7 -2
  10. package/dist/actions/package/compile/XyConfig.d.ts.map +1 -1
  11. package/dist/actions/package/compile/resolveTscBin.d.ts +10 -0
  12. package/dist/actions/package/compile/resolveTscBin.d.ts.map +1 -1
  13. package/dist/actions/package/compile/runTsc.d.ts.map +1 -1
  14. package/dist/bin/package/build.mjs +40 -2
  15. package/dist/bin/package/build.mjs.map +1 -1
  16. package/dist/bin/package/clean.mjs +34 -1
  17. package/dist/bin/package/clean.mjs.map +1 -1
  18. package/dist/bin/package/compile.mjs +46 -5
  19. package/dist/bin/package/compile.mjs.map +1 -1
  20. package/dist/bin/package/publint.mjs +34 -1
  21. package/dist/bin/package/publint.mjs.map +1 -1
  22. package/dist/bin/package/recompile.mjs +40 -2
  23. package/dist/bin/package/recompile.mjs.map +1 -1
  24. package/dist/bin/package/sync-layout.mjs +40 -4
  25. package/dist/bin/package/sync-layout.mjs.map +1 -1
  26. package/dist/bin/xy.mjs +431 -75
  27. package/dist/bin/xy.mjs.map +1 -1
  28. package/dist/xy/common/enable/index.d.ts +3 -0
  29. package/dist/xy/common/enable/index.d.ts.map +1 -0
  30. package/dist/xy/common/index.d.ts.map +1 -1
  31. package/package.json +8 -7
@@ -14,7 +14,7 @@ import Pe from "node:stream";
14
14
  import { StringDecoder } from "node:string_decoder";
15
15
  import Re from "path";
16
16
  import Ue from "os";
17
- import { TypeScriptLoader } from "cosmiconfig-typescript-loader";
17
+ import { createJiti } from "jiti";
18
18
  import ts, { formatDiagnosticsWithColorAndContext, sys } from "typescript";
19
19
  import { build } from "esbuild";
20
20
  //#region \0rolldown/runtime.js
@@ -7452,8 +7452,8 @@ var require_ExplorerSync = /* @__PURE__ */ __commonJSMin(((exports) => {
7452
7452
  exports.ExplorerSync = ExplorerSync;
7453
7453
  }));
7454
7454
  //#endregion
7455
- //#region src/lib/loadConfig.ts
7456
- var import_dist = (/* @__PURE__ */ __commonJSMin(((exports) => {
7455
+ //#region ../../node_modules/.pnpm/cosmiconfig@10.0.0/node_modules/cosmiconfig/dist/index.js
7456
+ var require_dist = /* @__PURE__ */ __commonJSMin(((exports) => {
7457
7457
  Object.defineProperty(exports, "__esModule", { value: true });
7458
7458
  exports.defaultLoadersSync = exports.defaultLoaders = exports.globalConfigSearchPlacesSync = exports.globalConfigSearchPlaces = exports.getDefaultSearchPlacesSync = exports.getDefaultSearchPlaces = exports.cosmiconfigSync = exports.cosmiconfig = void 0;
7459
7459
  const defaults_1 = require_defaults();
@@ -7613,7 +7613,43 @@ var import_dist = (/* @__PURE__ */ __commonJSMin(((exports) => {
7613
7613
  };
7614
7614
  }
7615
7615
  exports.cosmiconfigSync = cosmiconfigSync;
7616
- })))();
7616
+ }));
7617
+ //#endregion
7618
+ //#region ../../node_modules/.pnpm/cosmiconfig-typescript-loader@6.3.0_@types+node@26.2.0_cosmiconfig@10.0.0_typescript@6.0.3/node_modules/cosmiconfig-typescript-loader/dist/esm/typescript-compile-error.mjs
7619
+ var TypeScriptCompileError = class _TypeScriptCompileError extends Error {
7620
+ constructor(message) {
7621
+ super(message);
7622
+ this.name = this.constructor.name;
7623
+ Object.setPrototypeOf(this, new.target.prototype);
7624
+ }
7625
+ static fromError(error) {
7626
+ const message = `TypeScriptLoader failed to compile TypeScript:
7627
+ ${error.message}`;
7628
+ const newError = new _TypeScriptCompileError(message);
7629
+ newError.stack = error.stack;
7630
+ return newError;
7631
+ }
7632
+ };
7633
+ //#endregion
7634
+ //#region ../../node_modules/.pnpm/cosmiconfig-typescript-loader@6.3.0_@types+node@26.2.0_cosmiconfig@10.0.0_typescript@6.0.3/node_modules/cosmiconfig-typescript-loader/dist/esm/loader.mjs
7635
+ function TypeScriptLoader(options) {
7636
+ const loader = createJiti("", {
7637
+ interopDefault: true,
7638
+ ...options
7639
+ });
7640
+ return async (path, _content) => {
7641
+ try {
7642
+ const result = await loader.import(path);
7643
+ return result.default || result;
7644
+ } catch (error) {
7645
+ if (error instanceof Error) throw TypeScriptCompileError.fromError(error);
7646
+ throw error;
7647
+ }
7648
+ };
7649
+ }
7650
+ //#endregion
7651
+ //#region src/lib/loadConfig.ts
7652
+ var import_dist = require_dist();
7617
7653
  const configState = {
7618
7654
  config: void 0,
7619
7655
  /**
@@ -10453,6 +10489,10 @@ const warnDeprecatedEmptyObjectTargets = (targets) => {
10453
10489
  * `compile.nativePackage`.
10454
10490
  */
10455
10491
  const DEFAULT_NATIVE_PACKAGE = "typescript-native";
10492
+ /**
10493
+ * Full `package.json` alias spec for {@link DEFAULT_NATIVE_PACKAGE}.
10494
+ */
10495
+ const DEFAULT_NATIVE_ALIAS_SPEC = `npm:typescript@~7.0.2`;
10456
10496
  const readTscBinEntry = (packageJsonPath) => {
10457
10497
  const { bin } = JSON.parse(fs.readFileSync(packageJsonPath, "utf8"));
10458
10498
  if (typeof bin === "string") return bin;
@@ -10494,7 +10534,8 @@ const resolveCached = (packageName, fromDir) => {
10494
10534
  const missingNativeMessage = (packageName) => [
10495
10535
  `Compile: compile.compiler is "native" but "${packageName}" is not installed.`,
10496
10536
  " Add it as an alias so it does not collide with the compiler API package:",
10497
- ` "${packageName}": "npm:typescript@~7.0.2"`,
10537
+ ` "${packageName}": "${DEFAULT_NATIVE_ALIAS_SPEC}"`,
10538
+ " Or run: xy enable ts-native",
10498
10539
  " Keep \"typescript\" pinned to 6.x — ESLint and the xy analyzers load the compiler API from it."
10499
10540
  ].join("\n");
10500
10541
  /**