@clearlydev/nx-archweave 0.4.4 → 0.5.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.
Files changed (35) hide show
  1. package/README.md +13 -13
  2. package/dist/bin/review-verdict.js +2 -1
  3. package/dist/generators/_chunks/{chunk-3AE7MQPM.js → chunk-3ZHRZK5M.js} +5 -2
  4. package/dist/generators/_chunks/{chunk-FQHFT5IH.js → chunk-5Z7VZPES.js} +8 -1
  5. package/dist/generators/_chunks/{chunk-PB4CFJD5.js → chunk-624F6DEP.js} +11 -6
  6. package/dist/generators/_chunks/{chunk-HGEMEXKF.js → chunk-AON4KGZT.js} +6 -2
  7. package/dist/generators/_chunks/{chunk-GPZEZVPN.js → chunk-ILICA6LC.js} +5 -4
  8. package/dist/generators/_chunks/chunk-JPS6XKYK.js +12 -0
  9. package/dist/generators/_chunks/{chunk-JEQQCSOB.js → chunk-L3T4H7OF.js} +19 -15
  10. package/dist/generators/_chunks/{chunk-AFAORV5O.js → chunk-M7OQWSNF.js} +1 -1
  11. package/dist/generators/_chunks/{chunk-L2RZ2LBO.js → chunk-N6B6VBHG.js} +32 -8
  12. package/dist/generators/_chunks/{chunk-SNM66KYS.js → chunk-Q7IYHKT3.js} +9 -3
  13. package/dist/generators/_chunks/{chunk-AEAL4ICT.js → chunk-SEUY3OCQ.js} +3 -3
  14. package/dist/generators/_chunks/{chunk-5HMB6HYW.js → chunk-TJ6SCQLI.js} +21 -10
  15. package/dist/generators/_chunks/{chunk-QQNDYJTR.js → chunk-WNO3ZGBB.js} +3 -2
  16. package/dist/generators/_chunks/{chunk-B55SAIUS.js → chunk-WVMTOWLM.js} +1 -1
  17. package/dist/generators/_chunks/{chunk-2V5LX5NK.js → chunk-ZNTGYYLU.js} +7 -6
  18. package/dist/generators/add-agent-rules/generator.js +5 -4
  19. package/dist/generators/add-backend/generator.js +4 -4
  20. package/dist/generators/add-fsd-lite/generator.js +7 -5
  21. package/dist/generators/add-github-templates/generator.js +4 -3
  22. package/dist/generators/add-integration/generator.js +5 -5
  23. package/dist/generators/add-review/generator.js +6 -5
  24. package/dist/generators/allow-builds/generator.js +1 -1
  25. package/dist/generators/doctor/generator.js +235 -30
  26. package/dist/generators/entity/generator.js +5 -4
  27. package/dist/generators/feature/generator.js +5 -4
  28. package/dist/generators/init/generator.js +306 -63
  29. package/dist/generators/install-integration/generator.js +5 -5
  30. package/dist/generators/page/generator.js +5 -4
  31. package/dist/generators/shared/generator.js +5 -4
  32. package/dist/generators/widget/generator.js +5 -4
  33. package/package.json +1 -1
  34. package/src/generators/add-fsd-lite/schema.json +1 -1
  35. package/src/generators/init/schema.json +3 -3
@@ -2,14 +2,16 @@ import {
2
2
  addFsdLiteGenerator,
3
3
  generator_default,
4
4
  runAddFsdLite
5
- } from "../_chunks/chunk-5HMB6HYW.js";
6
- import "../_chunks/chunk-L2RZ2LBO.js";
7
- import "../_chunks/chunk-B55SAIUS.js";
5
+ } from "../_chunks/chunk-TJ6SCQLI.js";
6
+ import "../_chunks/chunk-N6B6VBHG.js";
7
+ import "../_chunks/chunk-WVMTOWLM.js";
8
8
  import "../_chunks/chunk-TXAQ2GJC.js";
9
9
  import "../_chunks/chunk-6ZTIUBB2.js";
10
+ import "../_chunks/chunk-JPS6XKYK.js";
10
11
  import "../_chunks/chunk-TUN34LAQ.js";
11
- import "../_chunks/chunk-AFAORV5O.js";
12
- import "../_chunks/chunk-FQHFT5IH.js";
12
+ import "../_chunks/chunk-ILICA6LC.js";
13
+ import "../_chunks/chunk-M7OQWSNF.js";
14
+ import "../_chunks/chunk-5Z7VZPES.js";
13
15
  export {
14
16
  addFsdLiteGenerator,
15
17
  generator_default as default,
@@ -6,11 +6,12 @@ import {
6
6
  addGithubTemplatesGenerator,
7
7
  generator_default,
8
8
  runAddGithubTemplates
9
- } from "../_chunks/chunk-3AE7MQPM.js";
9
+ } from "../_chunks/chunk-3ZHRZK5M.js";
10
10
  import "../_chunks/chunk-YNMLB4DL.js";
11
+ import "../_chunks/chunk-JPS6XKYK.js";
11
12
  import "../_chunks/chunk-TUN34LAQ.js";
12
- import "../_chunks/chunk-AFAORV5O.js";
13
- import "../_chunks/chunk-FQHFT5IH.js";
13
+ import "../_chunks/chunk-M7OQWSNF.js";
14
+ import "../_chunks/chunk-5Z7VZPES.js";
14
15
  export {
15
16
  BUG_REPORT_PATH,
16
17
  CODEOWNERS_PATH,
@@ -1,6 +1,3 @@
1
- import {
2
- diskRunNx
3
- } from "../_chunks/chunk-GPZEZVPN.js";
4
1
  import {
5
2
  DEFAULT_PLUGIN_SCOPE,
6
3
  PLUGIN_IDS,
@@ -11,8 +8,11 @@ import {
11
8
  renderUserCommand
12
9
  } from "../_chunks/chunk-AQHV7DJS.js";
13
10
  import "../_chunks/chunk-34V6HAJT.js";
14
- import "../_chunks/chunk-AFAORV5O.js";
15
- import "../_chunks/chunk-FQHFT5IH.js";
11
+ import {
12
+ diskRunNx
13
+ } from "../_chunks/chunk-ILICA6LC.js";
14
+ import "../_chunks/chunk-M7OQWSNF.js";
15
+ import "../_chunks/chunk-5Z7VZPES.js";
16
16
 
17
17
  // src/generators/add-integration/render.ts
18
18
  function renderIntegrationPlan(view) {
@@ -3,13 +3,14 @@ import {
3
3
  generator_default,
4
4
  recordedReview,
5
5
  runAddReview
6
- } from "../_chunks/chunk-AEAL4ICT.js";
7
- import "../_chunks/chunk-JEQQCSOB.js";
8
- import "../_chunks/chunk-HGEMEXKF.js";
6
+ } from "../_chunks/chunk-SEUY3OCQ.js";
7
+ import "../_chunks/chunk-L3T4H7OF.js";
8
+ import "../_chunks/chunk-AON4KGZT.js";
9
9
  import "../_chunks/chunk-YNMLB4DL.js";
10
+ import "../_chunks/chunk-JPS6XKYK.js";
10
11
  import "../_chunks/chunk-TUN34LAQ.js";
11
- import "../_chunks/chunk-AFAORV5O.js";
12
- import "../_chunks/chunk-FQHFT5IH.js";
12
+ import "../_chunks/chunk-M7OQWSNF.js";
13
+ import "../_chunks/chunk-5Z7VZPES.js";
13
14
  export {
14
15
  addReviewGenerator,
15
16
  generator_default as default,
@@ -3,7 +3,7 @@ import {
3
3
  } from "../_chunks/chunk-34V6HAJT.js";
4
4
  import {
5
5
  detectWorkspacePackageManager
6
- } from "../_chunks/chunk-FQHFT5IH.js";
6
+ } from "../_chunks/chunk-5Z7VZPES.js";
7
7
 
8
8
  // src/generators/allow-builds/generator.ts
9
9
  import { spawnSync } from "node:child_process";
@@ -3,7 +3,7 @@ import {
3
3
  } from "../_chunks/chunk-U6LAFHSF.js";
4
4
  import {
5
5
  detectUnitTestRunner
6
- } from "../_chunks/chunk-SNM66KYS.js";
6
+ } from "../_chunks/chunk-Q7IYHKT3.js";
7
7
  import "../_chunks/chunk-ASY3CK5L.js";
8
8
  import {
9
9
  REVIEW_MODES,
@@ -11,7 +11,7 @@ import {
11
11
  REVIEW_WORKFLOW_CONTRACT,
12
12
  ROUND_MARKER,
13
13
  judgeReviewFileConflict
14
- } from "../_chunks/chunk-JEQQCSOB.js";
14
+ } from "../_chunks/chunk-L3T4H7OF.js";
15
15
  import {
16
16
  createGroupDetector,
17
17
  indexFilePattern
@@ -21,14 +21,17 @@ import {
21
21
  } from "../_chunks/chunk-5MI3O4VZ.js";
22
22
  import {
23
23
  readSharedTypesConfig
24
- } from "../_chunks/chunk-QQNDYJTR.js";
24
+ } from "../_chunks/chunk-WNO3ZGBB.js";
25
25
  import {
26
- classifyFsdEslintConfig
27
- } from "../_chunks/chunk-L2RZ2LBO.js";
26
+ TOOLKIT_CONFIG_INPUT,
27
+ classifyFsdEslintConfig,
28
+ lintInputsProjectSnippet,
29
+ lintInputsTargetDefaultsSnippet
30
+ } from "../_chunks/chunk-N6B6VBHG.js";
28
31
  import {
29
32
  resolveFrontendApp,
30
33
  sourceRootOf
31
- } from "../_chunks/chunk-B55SAIUS.js";
34
+ } from "../_chunks/chunk-WVMTOWLM.js";
32
35
  import "../_chunks/chunk-TXAQ2GJC.js";
33
36
  import {
34
37
  ESLINT_CONFIG_CANDIDATES,
@@ -37,9 +40,7 @@ import {
37
40
  readBoundaryTags
38
41
  } from "../_chunks/chunk-6ZTIUBB2.js";
39
42
  import "../_chunks/chunk-YNMLB4DL.js";
40
- import {
41
- diskRunNx
42
- } from "../_chunks/chunk-GPZEZVPN.js";
43
+ import "../_chunks/chunk-JPS6XKYK.js";
43
44
  import {
44
45
  PLUGIN_CATALOG,
45
46
  createIntegrationsCompositionRoot,
@@ -47,13 +48,17 @@ import {
47
48
  verifyClaudeMarketplacePlugin
48
49
  } from "../_chunks/chunk-AQHV7DJS.js";
49
50
  import "../_chunks/chunk-34V6HAJT.js";
51
+ import {
52
+ diskRunNx
53
+ } from "../_chunks/chunk-ILICA6LC.js";
50
54
  import {
51
55
  readToolkitConfig,
52
56
  recordedFrontends
53
- } from "../_chunks/chunk-AFAORV5O.js";
57
+ } from "../_chunks/chunk-M7OQWSNF.js";
54
58
  import {
55
- detectWorkspacePackageManager
56
- } from "../_chunks/chunk-FQHFT5IH.js";
59
+ detectWorkspacePackageManager,
60
+ runNxCommand
61
+ } from "../_chunks/chunk-5Z7VZPES.js";
57
62
 
58
63
  // ../shared/dist/lib/doctor-report.js
59
64
  function createDoctorCheck(input) {
@@ -131,8 +136,8 @@ function detectEnvironment(root) {
131
136
  }
132
137
 
133
138
  // ../template-engine/dist/doctor/run-doctor-checks.js
134
- import { existsSync as existsSync6 } from "node:fs";
135
- import { join as join6 } from "node:path";
139
+ import { existsSync as existsSync7 } from "node:fs";
140
+ import { join as join7 } from "node:path";
136
141
 
137
142
  // ../template-engine/dist/doctor/review-checks.js
138
143
  import { existsSync as existsSync2, readdirSync, readFileSync as readFileSync2 } from "node:fs";
@@ -860,11 +865,209 @@ function buildFsdRuleAnchoredCheck(root, projects) {
860
865
  });
861
866
  }
862
867
 
868
+ // ../template-engine/dist/doctor/lint-cache-check.js
869
+ import { existsSync as existsSync6, readdirSync as readdirSync5, readFileSync as readFileSync5 } from "node:fs";
870
+ import { join as join6 } from "node:path";
871
+ var ESLINT_PLUGIN = "@nx/eslint/plugin";
872
+ var ESLINT_EXECUTOR = "@nx/eslint:lint";
873
+ var isObject = (value) => typeof value === "object" && value !== null && !Array.isArray(value);
874
+ function readJson(path) {
875
+ try {
876
+ const parsed = JSON.parse(readFileSync5(path, "utf-8"));
877
+ return isObject(parsed) ? parsed : null;
878
+ } catch {
879
+ return null;
880
+ }
881
+ }
882
+ function readLintSetup(root) {
883
+ const nxJson = readJson(join6(root, "nx.json"));
884
+ if (nxJson === null)
885
+ return null;
886
+ const plugins = Array.isArray(nxJson["plugins"]) ? nxJson["plugins"] : [];
887
+ const entry = plugins.find((plugin) => plugin === ESLINT_PLUGIN || isObject(plugin) && plugin["plugin"] === ESLINT_PLUGIN);
888
+ const options = isObject(entry) && isObject(entry["options"]) ? entry["options"] : {};
889
+ return {
890
+ target: typeof options["targetName"] === "string" ? options["targetName"] : "lint",
891
+ pluginRegistered: entry !== void 0,
892
+ targetDefaults: isObject(nxJson["targetDefaults"]) ? nxJson["targetDefaults"] : {},
893
+ namedInputs: isObject(nxJson["namedInputs"]) ? nxJson["namedInputs"] : {}
894
+ };
895
+ }
896
+ function projectList(root, projects) {
897
+ if (projects !== void 0)
898
+ return projects.map((project) => ({ name: project.name, root: project.root }));
899
+ const found = [];
900
+ for (const folder of ["apps", "libs"]) {
901
+ let entries = [];
902
+ try {
903
+ entries = readdirSync5(join6(root, folder), { withFileTypes: true }).filter((entry) => entry.isDirectory()).map((entry) => entry.name);
904
+ } catch {
905
+ continue;
906
+ }
907
+ for (const name of entries) {
908
+ const dir = `${folder}/${name}`;
909
+ const config = readJson(join6(root, dir, "project.json")) ?? readJson(join6(root, dir, "package.json"));
910
+ if (config === null)
911
+ continue;
912
+ found.push({ name: typeof config["name"] === "string" ? config["name"] : name, root: dir });
913
+ }
914
+ }
915
+ return found;
916
+ }
917
+ function ownLintTarget(root, project, target) {
918
+ const prefix = projectPrefix(project.root);
919
+ const candidates = [
920
+ [`${prefix}project.json`, (config) => isObject(config["targets"]) ? config["targets"][target] : void 0],
921
+ [`${prefix}package.json`, (config) => isObject(config["nx"]) && isObject(config["nx"]["targets"]) ? config["nx"]["targets"][target] : void 0]
922
+ ];
923
+ for (const [file, pick] of candidates) {
924
+ const config = readJson(join6(root, file));
925
+ if (config === null)
926
+ continue;
927
+ const own = pick(config);
928
+ if (!isObject(own))
929
+ continue;
930
+ return {
931
+ project: project.name,
932
+ file,
933
+ executor: typeof own["executor"] === "string" ? own["executor"] : void 0,
934
+ inputs: Array.isArray(own["inputs"]) ? own["inputs"] : void 0
935
+ };
936
+ }
937
+ const pkg = readJson(join6(root, `${prefix}package.json`));
938
+ if (pkg !== null && isObject(pkg["scripts"]) && typeof pkg["scripts"][target] === "string") {
939
+ return { project: project.name, file: `${prefix}package.json`, executor: "nx:run-script", inputs: void 0 };
940
+ }
941
+ return null;
942
+ }
943
+ function configFileOf(root, projectRoot) {
944
+ const prefix = projectPrefix(projectRoot);
945
+ return existsSync6(join6(root, `${prefix}project.json`)) ? `${prefix}project.json` : `${prefix}package.json`;
946
+ }
947
+ function defaultsInputs(setup, executor) {
948
+ for (const key of [executor ?? ESLINT_EXECUTOR, setup.target]) {
949
+ const entry = setup.targetDefaults[key];
950
+ if (isObject(entry) && Array.isArray(entry["inputs"]))
951
+ return entry["inputs"];
952
+ }
953
+ return void 0;
954
+ }
955
+ function carriesToolkitConfig(inputs, namedInputs) {
956
+ return inputs.some((input) => {
957
+ if (input === TOOLKIT_CONFIG_INPUT)
958
+ return true;
959
+ if (typeof input !== "string")
960
+ return false;
961
+ const named = namedInputs[input.replace(/^\^/, "")];
962
+ return Array.isArray(named) && named.includes(TOOLKIT_CONFIG_INPUT);
963
+ });
964
+ }
965
+ function namesOwnFiles(inputs) {
966
+ return inputs.some((input) => typeof input === "string" && (input === "default" || input === "production" || input.startsWith("{projectRoot}")));
967
+ }
968
+ function eslintConfigNames(root, projectRoot) {
969
+ const prefix = projectPrefix(projectRoot);
970
+ const own = ESLINT_CONFIG_CANDIDATES.find((name) => existsSync6(join6(root, `${prefix}${name}`)));
971
+ const workspace = ESLINT_CONFIG_CANDIDATES.find((name) => existsSync6(join6(root, name)));
972
+ return [
973
+ ...own === void 0 || prefix === "" ? [] : [`{projectRoot}/${own}`],
974
+ ...workspace === void 0 ? [] : [`{workspaceRoot}/${workspace}`]
975
+ ];
976
+ }
977
+ var NOT_READ = "nx.json could not be read";
978
+ function runNxAt(root) {
979
+ const detected = detectWorkspacePackageManager((path) => existsSync6(join6(root, path)), (path) => existsSync6(join6(root, path)) ? readFileSync5(join6(root, path), "utf-8") : void 0);
980
+ const recorded = readJson(join6(root, "toolkit.config.json"))?.["packageManager"];
981
+ const known = ["pnpm", "npm", "yarn", "bun"].includes(recorded) ? recorded : null;
982
+ return runNxCommand(detected ?? known);
983
+ }
984
+ function buildLintCacheCheck(root, projects) {
985
+ const id = "fsd-lint-cache";
986
+ const label = "Lint cache sees toolkit.config.json";
987
+ const setup = readLintSetup(root);
988
+ if (setup === null)
989
+ return createDoctorCheck({ id, label, status: "not-applicable", message: NOT_READ, evidence: [] });
990
+ const all = projectList(root, projects);
991
+ const fsdRoots = appliedFsdConfigs(root, projects).map((config) => config.replace(/\/?[^/]+$/, ""));
992
+ const fsdProjects = all.filter((project) => fsdRoots.includes(projectPrefix(project.root).replace(/\/$/, "")));
993
+ if (fsdRoots.length === 0) {
994
+ return createDoctorCheck({ id, label, status: "not-applicable", message: "no ESLint config wires the FSD rule", evidence: [] });
995
+ }
996
+ const missing = fsdProjects.filter((project) => {
997
+ if (projectPrefix(project.root) === "")
998
+ return false;
999
+ const own = ownLintTarget(root, project, setup.target);
1000
+ const inputs = own?.inputs ?? defaultsInputs(setup, own?.executor);
1001
+ return inputs === void 0 || !carriesToolkitConfig(inputs, setup.namedInputs);
1002
+ });
1003
+ if (missing.length === 0) {
1004
+ return createDoctorCheck({ id, label, status: "pass", message: "toolkit.config.json is among the FSD projects' lint inputs", evidence: [] });
1005
+ }
1006
+ const ownTargets = all.map((project) => ownLintTarget(root, project, setup.target)).filter((own) => own !== null);
1007
+ const lines = setup.pluginRegistered && ownTargets.length === 0 ? lintInputsTargetDefaultsSnippet(setup.target) : missing.flatMap((project) => {
1008
+ const own = ownLintTarget(root, project, setup.target);
1009
+ return lintInputsProjectSnippet({
1010
+ file: own?.file ?? configFileOf(root, project.root),
1011
+ target: setup.target,
1012
+ ownInputs: own?.inputs !== void 0,
1013
+ eslintConfigs: eslintConfigNames(root, project.root)
1014
+ });
1015
+ });
1016
+ const runNx = runNxAt(root);
1017
+ const skipCache = missing.map((project) => `${runNx} ${setup.target} ${project.name} --skip-nx-cache`).join(", ");
1018
+ return createDoctorCheck({
1019
+ id,
1020
+ label,
1021
+ status: "pass",
1022
+ message: "toolkit.config.json is not among lint's inputs: after a change to the fsd policy, Nx can replay a cached lint result",
1023
+ evidence: missing.map((project) => project.name),
1024
+ suggestedAction: [
1025
+ "A workspace init sets up from nx-archweave 0.5.0 on has it already (when its lint targets are inferred).",
1026
+ ...lines,
1027
+ `Or, after changing the fsd policy, check with: ${skipCache}`
1028
+ ].join("\n ")
1029
+ });
1030
+ }
1031
+ function buildLintInputsSpreadCheck(root, projects) {
1032
+ const id = "lint-inputs-spread";
1033
+ const label = "Lint targets keep their own inputs";
1034
+ const setup = readLintSetup(root);
1035
+ if (setup === null)
1036
+ return createDoctorCheck({ id, label, status: "not-applicable", message: NOT_READ, evidence: [] });
1037
+ const affected = projectList(root, projects).filter((project) => {
1038
+ const own = ownLintTarget(root, project, setup.target);
1039
+ if (own === null || own.inputs !== void 0)
1040
+ return false;
1041
+ const inputs = defaultsInputs(setup, own.executor);
1042
+ return inputs !== void 0 && inputs.includes("...") && !namesOwnFiles(inputs);
1043
+ });
1044
+ if (affected.length === 0) {
1045
+ return createDoctorCheck({ id, label, status: "pass", message: 'no lint target loses its own files to a "..." in targetDefaults', evidence: [] });
1046
+ }
1047
+ return createDoctorCheck({
1048
+ id,
1049
+ label,
1050
+ status: "warning",
1051
+ message: `targetDefaults gives the ${setup.target} target inputs with "...", but these projects write their own ${setup.target} target without inputs, so "..." has nothing to keep: their lint inputs leave out the project's files, and a source change can come back from the cache`,
1052
+ evidence: affected.map((project) => project.name),
1053
+ suggestedAction: [
1054
+ `Give each of these ${setup.target} targets its own inputs, or list "default" and "^default" in targetDefaults next to "...":`,
1055
+ ...affected.map((project) => {
1056
+ const own = ownLintTarget(root, project, setup.target);
1057
+ const inputs = ['"default"', '"^default"', ...eslintConfigNames(root, project.root).map((name) => `"${name}"`), '{ "externalDependencies": ["eslint"] }'];
1058
+ return `${project.name} (${own?.file ?? configFileOf(root, project.root)}): "inputs": [${inputs.join(", ")}]`;
1059
+ })
1060
+ ].join("\n ")
1061
+ });
1062
+ }
1063
+
863
1064
  // ../template-engine/dist/doctor/run-doctor-checks.js
864
1065
  var NOT_APPLICABLE_IDS = [
865
1066
  "fsd-like-structure",
866
1067
  "fsd-enforcement-applied",
867
1068
  "fsd-rule-anchored",
1069
+ "fsd-lint-cache",
1070
+ "lint-inputs-spread",
868
1071
  "nx-version",
869
1072
  "package-manager",
870
1073
  "workspace-root",
@@ -911,6 +1114,8 @@ function runDoctorChecks(root, projects, nxSupport) {
911
1114
  buildFsdLikeCheck(root, projects),
912
1115
  buildFsdEnforcementCheck(root, projects),
913
1116
  buildFsdRuleAnchoredCheck(root, projects),
1117
+ buildLintCacheCheck(root, projects),
1118
+ buildLintInputsSpreadCheck(root, projects),
914
1119
  createDoctorCheck({
915
1120
  id: "package-manager",
916
1121
  label: "Package manager",
@@ -1055,7 +1260,7 @@ function buildFrameworkChecks(env) {
1055
1260
  ];
1056
1261
  }
1057
1262
  function isToolkitManaged(root) {
1058
- return existsSync6(join6(root, "toolkit.config.json"));
1263
+ return existsSync7(join7(root, "toolkit.config.json"));
1059
1264
  }
1060
1265
  function buildExistingConfigCheck(root) {
1061
1266
  const exists = isToolkitManaged(root);
@@ -1068,7 +1273,7 @@ function buildExistingConfigCheck(root) {
1068
1273
  });
1069
1274
  }
1070
1275
  function buildIntegrationManifestCheck(root) {
1071
- const exists = existsSync6(join6(root, "archweave-integrations.json"));
1276
+ const exists = existsSync7(join7(root, "archweave-integrations.json"));
1072
1277
  return createDoctorCheck({
1073
1278
  id: "integration-manifest",
1074
1279
  label: "Integration manifest",
@@ -1078,8 +1283,8 @@ function buildIntegrationManifestCheck(root) {
1078
1283
  });
1079
1284
  }
1080
1285
  function buildAgentRulesCheck(root) {
1081
- const claudeExists = existsSync6(join6(root, "CLAUDE.md"));
1082
- const agentsExists = existsSync6(join6(root, "AGENTS.md"));
1286
+ const claudeExists = existsSync7(join7(root, "CLAUDE.md"));
1287
+ const agentsExists = existsSync7(join7(root, "AGENTS.md"));
1083
1288
  const exists = claudeExists || agentsExists;
1084
1289
  const evidence = [claudeExists && "CLAUDE.md", agentsExists && "AGENTS.md"].filter(Boolean);
1085
1290
  return createDoctorCheck({
@@ -1091,8 +1296,8 @@ function buildAgentRulesCheck(root) {
1091
1296
  });
1092
1297
  }
1093
1298
  function buildGithubTemplatesCheck(root) {
1094
- const issueTemplateExists = existsSync6(join6(root, ".github", "ISSUE_TEMPLATE"));
1095
- const prTemplateExists = existsSync6(join6(root, ".github", "PULL_REQUEST_TEMPLATE.md"));
1299
+ const issueTemplateExists = existsSync7(join7(root, ".github", "ISSUE_TEMPLATE"));
1300
+ const prTemplateExists = existsSync7(join7(root, ".github", "PULL_REQUEST_TEMPLATE.md"));
1096
1301
  const exists = issueTemplateExists || prTemplateExists;
1097
1302
  const managed = isToolkitManaged(root);
1098
1303
  return createDoctorCheck({
@@ -1229,16 +1434,16 @@ function buildIntegrationDoctorChecks(results) {
1229
1434
  }
1230
1435
 
1231
1436
  // ../integrations/dist/config/read-enabled-integrations.js
1232
- import { existsSync as existsSync7, readFileSync as readFileSync5 } from "node:fs";
1233
- import { join as join7 } from "node:path";
1437
+ import { existsSync as existsSync8, readFileSync as readFileSync6 } from "node:fs";
1438
+ import { join as join8 } from "node:path";
1234
1439
  var CONFIG_FILENAME = "toolkit.config.json";
1235
1440
  function readEnabledIntegrationIds(root) {
1236
- const configPath = join7(root, CONFIG_FILENAME);
1237
- if (!existsSync7(configPath)) {
1441
+ const configPath = join8(root, CONFIG_FILENAME);
1442
+ if (!existsSync8(configPath)) {
1238
1443
  return [];
1239
1444
  }
1240
1445
  try {
1241
- const parsed = JSON.parse(readFileSync5(configPath, "utf8"));
1446
+ const parsed = JSON.parse(readFileSync6(configPath, "utf8"));
1242
1447
  const enabled = parsed?.integrations?.enabled;
1243
1448
  return Array.isArray(enabled) && enabled.every((id) => typeof id === "string") ? enabled : [];
1244
1449
  } catch {
@@ -1438,14 +1643,14 @@ function buildPolicySuggestion(tree, sourceRoot, current) {
1438
1643
  status: "warning",
1439
1644
  message: `${deeper} of ${deeper + atSegment} imports into shared reach past a segment's index \u2014 with sharedPublicApi: segment the FSD rule reports each`,
1440
1645
  evidence: examples,
1441
- suggestedAction: 'If that is how this code is meant to be organised, set "fsd": { "sharedPublicApi": "file" } (or "component") in toolkit.config.json.'
1646
+ suggestedAction: 'If that is how this code is meant to be organised, add "sharedPublicApi": "file" (or "component") to the fsd object in toolkit.config.json, keeping its other keys.'
1442
1647
  });
1443
1648
  }
1444
1649
 
1445
1650
  // src/generators/doctor/nx-support.ts
1446
- import { readFileSync as readFileSync6 } from "node:fs";
1651
+ import { readFileSync as readFileSync7 } from "node:fs";
1447
1652
  import { createRequire } from "node:module";
1448
- import { join as join8 } from "node:path";
1653
+ import { join as join9 } from "node:path";
1449
1654
  var MAJORS_EITHER_SIDE = 1;
1450
1655
  function majorOf(version) {
1451
1656
  const match = /^(\d+)\./.exec(version.trim());
@@ -1454,7 +1659,7 @@ function majorOf(version) {
1454
1659
  function readOwnDevkitVersion() {
1455
1660
  try {
1456
1661
  const path = createRequire(import.meta.url).resolve("@nx/devkit/package.json");
1457
- const version = JSON.parse(readFileSync6(path, "utf-8")).version;
1662
+ const version = JSON.parse(readFileSync7(path, "utf-8")).version;
1458
1663
  return typeof version === "string" ? version : void 0;
1459
1664
  } catch {
1460
1665
  return void 0;
@@ -1462,7 +1667,7 @@ function readOwnDevkitVersion() {
1462
1667
  }
1463
1668
  function readInstalledNx(root) {
1464
1669
  try {
1465
- const version = JSON.parse(readFileSync6(join8(root, "node_modules", "nx", "package.json"), "utf-8")).version;
1670
+ const version = JSON.parse(readFileSync7(join9(root, "node_modules", "nx", "package.json"), "utf-8")).version;
1466
1671
  return typeof version === "string" ? version : void 0;
1467
1672
  } catch {
1468
1673
  return void 0;
@@ -3,16 +3,17 @@ import {
3
3
  } from "../_chunks/chunk-H222FPLK.js";
4
4
  import {
5
5
  runFsdSlice
6
- } from "../_chunks/chunk-SNM66KYS.js";
7
- import "../_chunks/chunk-B55SAIUS.js";
6
+ } from "../_chunks/chunk-Q7IYHKT3.js";
7
+ import "../_chunks/chunk-WVMTOWLM.js";
8
8
  import "../_chunks/chunk-TXAQ2GJC.js";
9
9
  import "../_chunks/chunk-6ZTIUBB2.js";
10
10
  import "../_chunks/chunk-YNMLB4DL.js";
11
+ import "../_chunks/chunk-JPS6XKYK.js";
11
12
  import {
12
13
  resolveDryRun
13
14
  } from "../_chunks/chunk-TUN34LAQ.js";
14
- import "../_chunks/chunk-AFAORV5O.js";
15
- import "../_chunks/chunk-FQHFT5IH.js";
15
+ import "../_chunks/chunk-M7OQWSNF.js";
16
+ import "../_chunks/chunk-5Z7VZPES.js";
16
17
 
17
18
  // src/generators/entity/generator.ts
18
19
  async function entityGenerator(tree, options) {
@@ -3,16 +3,17 @@ import {
3
3
  } from "../_chunks/chunk-H222FPLK.js";
4
4
  import {
5
5
  runFsdSlice
6
- } from "../_chunks/chunk-SNM66KYS.js";
7
- import "../_chunks/chunk-B55SAIUS.js";
6
+ } from "../_chunks/chunk-Q7IYHKT3.js";
7
+ import "../_chunks/chunk-WVMTOWLM.js";
8
8
  import "../_chunks/chunk-TXAQ2GJC.js";
9
9
  import "../_chunks/chunk-6ZTIUBB2.js";
10
10
  import "../_chunks/chunk-YNMLB4DL.js";
11
+ import "../_chunks/chunk-JPS6XKYK.js";
11
12
  import {
12
13
  resolveDryRun
13
14
  } from "../_chunks/chunk-TUN34LAQ.js";
14
- import "../_chunks/chunk-AFAORV5O.js";
15
- import "../_chunks/chunk-FQHFT5IH.js";
15
+ import "../_chunks/chunk-M7OQWSNF.js";
16
+ import "../_chunks/chunk-5Z7VZPES.js";
16
17
 
17
18
  // src/generators/feature/generator.ts
18
19
  async function featureGenerator(tree, options) {