@decantr/cli 3.5.1 → 3.5.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.
package/dist/bin.js CHANGED
@@ -1,6 +1,6 @@
1
1
  #!/usr/bin/env node
2
- import "./chunk-S3ZDXBRM.js";
2
+ import "./chunk-6FR73WZ6.js";
3
3
  import "./chunk-SIDKK73N.js";
4
- import "./chunk-MDQSTAP5.js";
5
- import "./chunk-EUEQMXN5.js";
4
+ import "./chunk-GDPC7PCB.js";
5
+ import "./chunk-GJG3O4QS.js";
6
6
  import "./chunk-PM7DKABI.js";
@@ -22,7 +22,7 @@ import {
22
22
  listWorkspaceCandidates,
23
23
  listWorkspaceProjects,
24
24
  shouldFailWorkspaceHealth
25
- } from "./chunk-MDQSTAP5.js";
25
+ } from "./chunk-GDPC7PCB.js";
26
26
  import {
27
27
  acceptBrownfieldLocalLaw,
28
28
  acceptStyleBridge,
@@ -52,7 +52,7 @@ import {
52
52
  writeBrownfieldCodifyProposal,
53
53
  writeHostedPatternMappingProposal,
54
54
  writeStyleBridgeProposal
55
- } from "./chunk-EUEQMXN5.js";
55
+ } from "./chunk-GJG3O4QS.js";
56
56
  import {
57
57
  buildGuardRegistryContext,
58
58
  createDoctrineMap,
@@ -4474,13 +4474,16 @@ function inspectGraphArtifacts(appRoot, workspaceRoot) {
4474
4474
  };
4475
4475
  }
4476
4476
  }
4477
- function buildDoctorReport(root, args) {
4478
- let projectArg;
4477
+ function parseDoctorProjectArg(args) {
4479
4478
  for (let index = 1; index < args.length; index += 1) {
4480
4479
  const arg = args[index];
4481
- if (arg === "--project" && args[index + 1]) projectArg = args[++index];
4482
- else if (arg.startsWith("--project=")) projectArg = arg.slice("--project=".length);
4480
+ if (arg === "--project" && args[index + 1]) return args[index + 1];
4481
+ if (arg.startsWith("--project=")) return arg.slice("--project=".length);
4483
4482
  }
4483
+ return void 0;
4484
+ }
4485
+ function buildDoctorReport(root, args) {
4486
+ const projectArg = parseDoctorProjectArg(args);
4484
4487
  const workspaceMode = args.includes("--workspace");
4485
4488
  const workspaceInfo = resolveWorkspaceInfo(root, projectArg);
4486
4489
  const workspaceRoot = workspaceInfo.workspaceRoot;
@@ -4843,6 +4846,18 @@ ${BOLD3}Examples:${RESET4}
4843
4846
  `);
4844
4847
  }
4845
4848
  async function cmdDoctor(args = ["doctor"], root = process.cwd()) {
4849
+ const projectArg = parseDoctorProjectArg(args);
4850
+ const workspaceMode = args.includes("--workspace");
4851
+ if (projectArg && !args.includes("--json")) {
4852
+ const workspaceInfo = resolveWorkspaceInfo(root, projectArg);
4853
+ const appRoot = workspaceMode ? workspaceInfo.workspaceRoot : workspaceInfo.appRoot;
4854
+ if (!existsSync15(appRoot)) {
4855
+ console.error(`${RED3}Project path does not exist: ${projectArg}${RESET4}`);
4856
+ console.error(`${DIM4}Run decantr workspace list to see detected app candidates.${RESET4}`);
4857
+ process.exitCode = 1;
4858
+ return;
4859
+ }
4860
+ }
4846
4861
  const report = buildDoctorReport(root, args);
4847
4862
  if (args.includes("--json")) {
4848
4863
  console.log(JSON.stringify(report, null, 2));
@@ -11058,7 +11073,7 @@ async function cmdAdoptWorkflow(args) {
11058
11073
  await cmdGraph(projectRoot, { displayRoot: process.cwd() });
11059
11074
  if (process.exitCode && process.exitCode !== 0) return;
11060
11075
  if (runVerify) {
11061
- const { cmdHealth } = await import("./health-5S2L44SX.js");
11076
+ const { cmdHealth } = await import("./health-G7Z7L5TV.js");
11062
11077
  await cmdHealth(projectRoot, {
11063
11078
  browser: runBrowser,
11064
11079
  browserBaseUrl: baseUrl,
@@ -11132,7 +11147,7 @@ async function cmdVerifyWorkflow(args) {
11132
11147
  return;
11133
11148
  }
11134
11149
  if (workspaceMode) {
11135
- const { cmdWorkspace } = await import("./workspace-UIKTIWUN.js");
11150
+ const { cmdWorkspace } = await import("./workspace-F3KQMALN.js");
11136
11151
  await cmdWorkspace(process.cwd(), ["workspace", "health", ...withoutWorkflowOnlyFlags(args)]);
11137
11152
  return;
11138
11153
  }
@@ -11175,7 +11190,7 @@ async function cmdVerifyWorkflow(args) {
11175
11190
  process.exitCode = void 0;
11176
11191
  }
11177
11192
  }
11178
- const { cmdHealth, parseHealthArgs } = await import("./health-5S2L44SX.js");
11193
+ const { cmdHealth, parseHealthArgs } = await import("./health-G7Z7L5TV.js");
11179
11194
  await cmdHealth(workspaceInfo.appRoot, parseHealthArgs(healthArgs));
11180
11195
  if (localPatterns) {
11181
11196
  const validation = validateLocalLaw(workspaceInfo.appRoot);
@@ -12837,7 +12852,7 @@ async function main() {
12837
12852
  const { flags } = parseLooseArgs(args);
12838
12853
  const workspaceInfo = resolveWorkflowProject(flags, "health");
12839
12854
  if (!workspaceInfo) break;
12840
- const { cmdHealth, parseHealthArgs } = await import("./health-5S2L44SX.js");
12855
+ const { cmdHealth, parseHealthArgs } = await import("./health-G7Z7L5TV.js");
12841
12856
  await cmdHealth(workspaceInfo.appRoot, parseHealthArgs(stripProjectArgs(args)));
12842
12857
  } catch (e) {
12843
12858
  console.error(error2(e.message));
@@ -12865,7 +12880,7 @@ async function main() {
12865
12880
  cmdStudioHelp();
12866
12881
  break;
12867
12882
  }
12868
- const { cmdStudio, parseStudioArgs } = await import("./studio-EN347SLA.js");
12883
+ const { cmdStudio, parseStudioArgs } = await import("./studio-QG7MX3QS.js");
12869
12884
  await cmdStudio(process.cwd(), parseStudioArgs(args));
12870
12885
  } catch (e) {
12871
12886
  console.error(error2(e.message));
@@ -12879,7 +12894,7 @@ async function main() {
12879
12894
  cmdWorkspaceHelp();
12880
12895
  break;
12881
12896
  }
12882
- const { cmdWorkspace } = await import("./workspace-UIKTIWUN.js");
12897
+ const { cmdWorkspace } = await import("./workspace-F3KQMALN.js");
12883
12898
  await cmdWorkspace(process.cwd(), args);
12884
12899
  } catch (e) {
12885
12900
  console.error(error2(e.message));
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  createProjectHealthReport,
3
3
  listWorkspaceAppCandidates
4
- } from "./chunk-EUEQMXN5.js";
4
+ } from "./chunk-GJG3O4QS.js";
5
5
 
6
6
  // src/commands/workspace.ts
7
7
  import { execFileSync } from "child_process";
@@ -1836,7 +1836,7 @@ function pathAliasTargetCandidates(source, config) {
1836
1836
  if (!source.startsWith(prefix) || !source.endsWith(suffix)) continue;
1837
1837
  const matched = source.slice(prefix.length, source.length - suffix.length);
1838
1838
  for (const target of alias.targets) {
1839
- candidates.push(target.replace("*", matched));
1839
+ candidates.push(target.split("*").join(matched));
1840
1840
  }
1841
1841
  }
1842
1842
  if (config.baseUrl) {
@@ -13,7 +13,7 @@ import {
13
13
  renderProjectHealthCiWorkflow,
14
14
  shouldFailHealth,
15
15
  writeProjectHealthCiWorkflow
16
- } from "./chunk-EUEQMXN5.js";
16
+ } from "./chunk-GJG3O4QS.js";
17
17
  import "./chunk-PM7DKABI.js";
18
18
  export {
19
19
  cmdHealth,
package/dist/index.js CHANGED
@@ -1,5 +1,5 @@
1
- import "./chunk-S3ZDXBRM.js";
1
+ import "./chunk-6FR73WZ6.js";
2
2
  import "./chunk-SIDKK73N.js";
3
- import "./chunk-MDQSTAP5.js";
4
- import "./chunk-EUEQMXN5.js";
3
+ import "./chunk-GDPC7PCB.js";
4
+ import "./chunk-GJG3O4QS.js";
5
5
  import "./chunk-PM7DKABI.js";
@@ -1,9 +1,9 @@
1
1
  import {
2
2
  createWorkspaceHealthReport
3
- } from "./chunk-MDQSTAP5.js";
3
+ } from "./chunk-GDPC7PCB.js";
4
4
  import {
5
5
  createProjectHealthReport
6
- } from "./chunk-EUEQMXN5.js";
6
+ } from "./chunk-GJG3O4QS.js";
7
7
  import {
8
8
  sendStudioHealthRefreshedTelemetry,
9
9
  sendStudioStartedTelemetry
@@ -7,8 +7,8 @@ import {
7
7
  listWorkspaceProjects,
8
8
  parseWorkspaceArgs,
9
9
  shouldFailWorkspaceHealth
10
- } from "./chunk-MDQSTAP5.js";
11
- import "./chunk-EUEQMXN5.js";
10
+ } from "./chunk-GDPC7PCB.js";
11
+ import "./chunk-GJG3O4QS.js";
12
12
  import "./chunk-PM7DKABI.js";
13
13
  export {
14
14
  cmdWorkspace,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@decantr/cli",
3
- "version": "3.5.1",
3
+ "version": "3.5.2",
4
4
  "description": "Decantr CLI - adopt, verify, graph, and govern frontend codebases touched by AI agents",
5
5
  "keywords": [
6
6
  "decantr",
@@ -50,10 +50,10 @@
50
50
  "dependencies": {
51
51
  "ajv": "^8.20.0",
52
52
  "@decantr/core": "3.5.0",
53
- "@decantr/registry": "3.4.0",
53
+ "@decantr/essence-spec": "3.4.0",
54
54
  "@decantr/telemetry": "3.4.0",
55
- "@decantr/verifier": "3.5.0",
56
- "@decantr/essence-spec": "3.4.0"
55
+ "@decantr/registry": "3.4.0",
56
+ "@decantr/verifier": "3.5.0"
57
57
  },
58
58
  "scripts": {
59
59
  "build": "tsup",