@decantr/cli 2.9.2 → 2.9.4

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.
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  createProjectHealthReport,
3
3
  listWorkspaceAppCandidates
4
- } from "./chunk-DX2UDORT.js";
4
+ } from "./chunk-FACL3NXU.js";
5
5
 
6
6
  // src/commands/workspace.ts
7
7
  import { execFileSync } from "child_process";
@@ -322,7 +322,7 @@ async function cmdWorkspace(workspaceRoot = process.cwd(), args = ["workspace"])
322
322
  }
323
323
  if (unattachedCandidates.length > 0) {
324
324
  console.log("");
325
- console.log("Start by attaching one app:");
325
+ console.log(projects.length > 0 ? "Attach another app:" : "Start by attaching one app:");
326
326
  console.log(` ${unattachedCandidates[0].suggestedAdoptCommand}`);
327
327
  }
328
328
  return;
@@ -1323,6 +1323,22 @@ var SKIP_DIRECTORIES = /* @__PURE__ */ new Set([
1323
1323
  ".cache"
1324
1324
  ]);
1325
1325
  var MAX_FILE_SIZE = 1024 * 1024;
1326
+ function isNonUiInteractionSource(relativePath) {
1327
+ const normalized2 = relativePath.replace(/\\/g, "/");
1328
+ if (/\.d\.ts$/i.test(normalized2)) return true;
1329
+ if (/(?:^|\/)(?:__tests__|__mocks__|tests?|specs?|fixtures?|mocks?|stories?)(?:\/|$)/i.test(
1330
+ normalized2
1331
+ )) {
1332
+ return true;
1333
+ }
1334
+ if (/\.(?:test|spec|stories?|story|fixture|mock)\.(?:[cm]?[jt]sx?|mdx|html)$/i.test(normalized2)) {
1335
+ return true;
1336
+ }
1337
+ if (/^(?:src\/)?app\/api\//i.test(normalized2)) return true;
1338
+ if (/^(?:src\/)?pages\/api\//i.test(normalized2)) return true;
1339
+ if (/(?:^|\/)route\.[cm]?[jt]s$/i.test(normalized2)) return true;
1340
+ return false;
1341
+ }
1326
1342
  function walkSourceTree(rootDir) {
1327
1343
  const sources = /* @__PURE__ */ new Map();
1328
1344
  function walk2(dir) {
@@ -1341,12 +1357,14 @@ function walkSourceTree(rootDir) {
1341
1357
  } catch {
1342
1358
  continue;
1343
1359
  }
1360
+ const relativePath = relative3(rootDir, fullPath) || entry;
1344
1361
  if (s.isDirectory()) {
1345
1362
  walk2(fullPath);
1346
1363
  } else if (s.isFile() && SCAN_EXTENSIONS.has(extname2(entry))) {
1347
1364
  if (s.size > MAX_FILE_SIZE) continue;
1365
+ if (isNonUiInteractionSource(relativePath)) continue;
1348
1366
  try {
1349
- sources.set(relative3(rootDir, fullPath) || entry, readFileSync8(fullPath, "utf8"));
1367
+ sources.set(relativePath, readFileSync8(fullPath, "utf8"));
1350
1368
  } catch {
1351
1369
  }
1352
1370
  }
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  cmdHeal,
3
3
  collectCheckIssues
4
- } from "./chunk-34TZXWIF.js";
4
+ } from "./chunk-WONPNSSI.js";
5
5
  export {
6
6
  cmdHeal,
7
7
  collectCheckIssues
@@ -10,8 +10,8 @@ import {
10
10
  renderProjectHealthCiWorkflow,
11
11
  shouldFailHealth,
12
12
  writeProjectHealthCiWorkflow
13
- } from "./chunk-DX2UDORT.js";
14
- import "./chunk-34TZXWIF.js";
13
+ } from "./chunk-FACL3NXU.js";
14
+ import "./chunk-WONPNSSI.js";
15
15
  export {
16
16
  cmdHealth,
17
17
  collectDesignTokenEvidence,
package/dist/index.js CHANGED
@@ -1,5 +1,5 @@
1
- import "./chunk-AXMGQ5IB.js";
1
+ import "./chunk-GDGZFGMK.js";
2
2
  import "./chunk-RXF7ZYGK.js";
3
- import "./chunk-R57DMFLF.js";
4
- import "./chunk-DX2UDORT.js";
5
- import "./chunk-34TZXWIF.js";
3
+ import "./chunk-VCUFZB45.js";
4
+ import "./chunk-FACL3NXU.js";
5
+ import "./chunk-WONPNSSI.js";
@@ -1,13 +1,13 @@
1
1
  import {
2
2
  createWorkspaceHealthReport
3
- } from "./chunk-R57DMFLF.js";
3
+ } from "./chunk-VCUFZB45.js";
4
4
  import {
5
5
  createProjectHealthReport
6
- } from "./chunk-DX2UDORT.js";
6
+ } from "./chunk-FACL3NXU.js";
7
7
  import {
8
8
  sendStudioHealthRefreshedTelemetry,
9
9
  sendStudioStartedTelemetry
10
- } from "./chunk-34TZXWIF.js";
10
+ } from "./chunk-WONPNSSI.js";
11
11
 
12
12
  // src/commands/studio.ts
13
13
  import { readFileSync } from "fs";
@@ -7,9 +7,9 @@ import {
7
7
  listWorkspaceProjects,
8
8
  parseWorkspaceArgs,
9
9
  shouldFailWorkspaceHealth
10
- } from "./chunk-R57DMFLF.js";
11
- import "./chunk-DX2UDORT.js";
12
- import "./chunk-34TZXWIF.js";
10
+ } from "./chunk-VCUFZB45.js";
11
+ import "./chunk-FACL3NXU.js";
12
+ import "./chunk-WONPNSSI.js";
13
13
  export {
14
14
  cmdWorkspace,
15
15
  createWorkspaceHealthReport,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@decantr/cli",
3
- "version": "2.9.2",
3
+ "version": "2.9.4",
4
4
  "description": "Decantr CLI - scaffold, audit, inspect Project Health, and maintain Decantr projects from the terminal",
5
5
  "keywords": [
6
6
  "decantr",
@@ -52,7 +52,7 @@
52
52
  "@decantr/essence-spec": "2.0.1",
53
53
  "@decantr/registry": "2.2.0",
54
54
  "@decantr/telemetry": "2.2.1",
55
- "@decantr/verifier": "2.3.2"
55
+ "@decantr/verifier": "2.3.3"
56
56
  },
57
57
  "scripts": {
58
58
  "build": "tsup",