@tdk-landscape/tdk-cli-core 1.3.138 → 1.3.140

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 (158) hide show
  1. package/cli/dist/backend-frameworks/elysia.js +0 -1
  2. package/cli/dist/backend-frameworks/express.js +0 -1
  3. package/cli/dist/backend-frameworks/fastify.js +0 -1
  4. package/cli/dist/backend-frameworks/h3.js +0 -1
  5. package/cli/dist/backend-frameworks/koa.js +0 -1
  6. package/cli/dist/backend-frameworks/mcp.js +0 -1
  7. package/cli/dist/backend-frameworks/nestjs.js +0 -1
  8. package/cli/dist/backend-frameworks/registry.js +0 -1
  9. package/cli/dist/backend-frameworks/types.js +0 -1
  10. package/cli/dist/backend-languages/bun.js +0 -1
  11. package/cli/dist/backend-languages/go.js +0 -1
  12. package/cli/dist/backend-languages/python.js +0 -1
  13. package/cli/dist/backend-languages/registry.js +0 -1
  14. package/cli/dist/backend-languages/rust.js +0 -1
  15. package/cli/dist/backend-languages/types.js +0 -1
  16. package/cli/dist/cli.js +0 -1
  17. package/cli/dist/commands/__tests__/project-e2e-helpers.js +0 -1
  18. package/cli/dist/commands/completion.js +0 -1
  19. package/cli/dist/commands/config.js +3 -14
  20. package/cli/dist/commands/doctor.js +10 -11
  21. package/cli/dist/commands/down.js +0 -1
  22. package/cli/dist/commands/eject.js +0 -1
  23. package/cli/dist/commands/help.js +0 -1
  24. package/cli/dist/commands/import.js +0 -1
  25. package/cli/dist/commands/logs.js +0 -1
  26. package/cli/dist/commands/maintainers.js +0 -1
  27. package/cli/dist/commands/mcp.js +0 -1
  28. package/cli/dist/commands/networks.js +0 -2
  29. package/cli/dist/commands/project.js +3 -4
  30. package/cli/dist/commands/projects.js +0 -1
  31. package/cli/dist/commands/resource.js +11 -10
  32. package/cli/dist/commands/resources.js +0 -1
  33. package/cli/dist/commands/runtime.js +0 -1
  34. package/cli/dist/commands/stack.js +0 -1
  35. package/cli/dist/commands/stacks.js +0 -1
  36. package/cli/dist/commands/status.js +0 -1
  37. package/cli/dist/commands/ui.js +8 -13
  38. package/cli/dist/commands/up.js +6 -7
  39. package/cli/dist/commands/upgrade.js +2 -2
  40. package/cli/dist/commands/version.js +0 -1
  41. package/cli/dist/components/Accessible.js +4 -3
  42. package/cli/dist/components/BaseTooltip.js +0 -1
  43. package/cli/dist/components/DetailPanel.js +0 -1
  44. package/cli/dist/components/FileTree.js +0 -1
  45. package/cli/dist/components/ResourceSelectInput.js +3 -3
  46. package/cli/dist/components/ResourceTable.js +0 -1
  47. package/cli/dist/components/ServiceIssues.js +0 -1
  48. package/cli/dist/components/TUIHeader.js +0 -1
  49. package/cli/dist/components/TabBar.js +0 -1
  50. package/cli/dist/components/Tooltip.js +0 -1
  51. package/cli/dist/components/index.js +0 -1
  52. package/cli/dist/components/ui-theme.js +5 -1
  53. package/cli/dist/config/platform-standards.js +0 -1
  54. package/cli/dist/frontend-frameworks/lit.js +0 -1
  55. package/cli/dist/frontend-frameworks/preact.js +0 -1
  56. package/cli/dist/frontend-frameworks/qwik.js +0 -1
  57. package/cli/dist/frontend-frameworks/react.js +0 -1
  58. package/cli/dist/frontend-frameworks/registry.js +0 -1
  59. package/cli/dist/frontend-frameworks/solid.js +0 -1
  60. package/cli/dist/frontend-frameworks/svelte.js +1 -2
  61. package/cli/dist/frontend-frameworks/tanstack-router.js +0 -1
  62. package/cli/dist/frontend-frameworks/types.js +0 -1
  63. package/cli/dist/frontend-frameworks/vanilla.js +0 -1
  64. package/cli/dist/frontend-frameworks/vue.js +0 -1
  65. package/cli/dist/generator/__tests__/golden-helpers.js +0 -1
  66. package/cli/dist/generator/extension-fetch.js +0 -1
  67. package/cli/dist/generator/resource-templates.js +0 -1
  68. package/cli/dist/generator/template-engine.js +9 -10
  69. package/cli/dist/index.js +0 -1
  70. package/cli/dist/mcp/server.js +0 -1
  71. package/cli/dist/mcp/tools.js +0 -1
  72. package/cli/dist/types/index.js +4 -6
  73. package/cli/dist/utils/agent-host.js +0 -1
  74. package/cli/dist/utils/atomic-write.js +0 -1
  75. package/cli/dist/utils/bun-floor.js +0 -1
  76. package/cli/dist/utils/bun-requirement.js +0 -1
  77. package/cli/dist/utils/cache.js +0 -1
  78. package/cli/dist/utils/cold-preflight.js +2 -2
  79. package/cli/dist/utils/command-helpers.js +0 -1
  80. package/cli/dist/utils/constants.js +18 -4
  81. package/cli/dist/utils/discovery-context.js +0 -1
  82. package/cli/dist/utils/discovery-paths.js +2 -2
  83. package/cli/dist/utils/docker.js +0 -1
  84. package/cli/dist/utils/doctor-report.js +0 -1
  85. package/cli/dist/utils/doctor-runtime.js +4 -5
  86. package/cli/dist/utils/doctor-starlark.js +0 -1
  87. package/cli/dist/utils/doctor-wiring.js +8 -9
  88. package/cli/dist/utils/down-cleanup.js +0 -1
  89. package/cli/dist/utils/env-validator.js +0 -1
  90. package/cli/dist/utils/errors.js +2 -3
  91. package/cli/dist/utils/exec-async.js +0 -1
  92. package/cli/dist/utils/file-helpers.js +1 -3
  93. package/cli/dist/utils/formatting.js +0 -1
  94. package/cli/dist/utils/generated-paths.js +5 -6
  95. package/cli/dist/utils/help-command.js +0 -1
  96. package/cli/dist/utils/host-port-config.js +2 -2
  97. package/cli/dist/utils/host-port-plan.js +0 -1
  98. package/cli/dist/utils/json-output.js +0 -1
  99. package/cli/dist/utils/machine-output.js +0 -1
  100. package/cli/dist/utils/paths.js +2 -2
  101. package/cli/dist/utils/platform.js +0 -1
  102. package/cli/dist/utils/port-assignment.js +0 -1
  103. package/cli/dist/utils/port-conflict-fix.js +0 -1
  104. package/cli/dist/utils/port-fallback-notice.js +0 -1
  105. package/cli/dist/utils/port-listener-probe.js +0 -1
  106. package/cli/dist/utils/project-config-defaults.js +0 -1
  107. package/cli/dist/utils/project-features.js +0 -1
  108. package/cli/dist/utils/project-templates.js +0 -1
  109. package/cli/dist/utils/prompt.js +0 -1
  110. package/cli/dist/utils/resource-features.js +0 -1
  111. package/cli/dist/utils/resource-kind.js +0 -1
  112. package/cli/dist/utils/schema-version-gate.js +0 -1
  113. package/cli/dist/utils/search-status.js +0 -1
  114. package/cli/dist/utils/secret-redaction.js +0 -1
  115. package/cli/dist/utils/service-config-checks.js +0 -1
  116. package/cli/dist/utils/service-manifest.js +0 -1
  117. package/cli/dist/utils/service-runtime-state.js +0 -1
  118. package/cli/dist/utils/service-urls.js +2 -2
  119. package/cli/dist/utils/services.js +3 -6
  120. package/cli/dist/utils/shared-platform-postgres.js +2 -3
  121. package/cli/dist/utils/single-flight.js +0 -1
  122. package/cli/dist/utils/smoke.js +0 -1
  123. package/cli/dist/utils/spinner.js +0 -1
  124. package/cli/dist/utils/stack-features.js +0 -1
  125. package/cli/dist/utils/stack-status.js +0 -1
  126. package/cli/dist/utils/startup-report.js +0 -1
  127. package/cli/dist/utils/status-message.js +0 -1
  128. package/cli/dist/utils/status-ports.js +0 -1
  129. package/cli/dist/utils/suggestions.js +6 -3
  130. package/cli/dist/utils/tar.js +5 -4
  131. package/cli/dist/utils/tdk-version.js +2 -2
  132. package/cli/dist/utils/terminal-layout.js +0 -1
  133. package/cli/dist/utils/tilt-events.js +0 -1
  134. package/cli/dist/utils/tilt-logs.js +0 -1
  135. package/cli/dist/utils/tilt-process.js +0 -1
  136. package/cli/dist/utils/tilt-resource-state.js +0 -1
  137. package/cli/dist/utils/tilt-startup.js +0 -1
  138. package/cli/dist/utils/tilt-unreachable-message.js +0 -1
  139. package/cli/dist/utils/tilt.js +0 -1
  140. package/cli/dist/utils/ui-keymap.js +1 -2
  141. package/cli/dist/utils/ui-service-state.js +0 -1
  142. package/cli/dist/utils/up-only.js +0 -1
  143. package/cli/dist/utils/up-readiness.js +0 -1
  144. package/cli/dist/utils/validation.js +0 -1
  145. package/cli/dist/utils/which.js +0 -1
  146. package/cli/dist/utils/windows-doctor.js +0 -1
  147. package/cli/dist-bundle/chunk-42IVF3YT.js +3 -0
  148. package/cli/dist-bundle/chunk-LMHD62S4.js +315 -0
  149. package/cli/dist-bundle/cli.js +211 -211
  150. package/cli/dist-bundle/{cold-preflight-6VMSECY4.js → cold-preflight-O6LMFPMR.js} +1 -1
  151. package/cli/dist-bundle/{extension-fetch-COIG2KR6.js → extension-fetch-6XNTDF44.js} +1 -1
  152. package/cli/package.json +1 -1
  153. package/engine/topologies/platform/docker/AGENTS.md +13 -13
  154. package/engine/topologies/platform/docker/dockerfile/language_dockerfile.star +6 -2
  155. package/engine/topologies/tilt/manifest/README.md +1 -15
  156. package/package.json +1 -1
  157. package/cli/dist-bundle/chunk-OBQS5CYC.js +0 -3
  158. package/cli/dist-bundle/chunk-Q6PZ6ZPA.js +0 -315
@@ -36,4 +36,3 @@ export const elysiaBackendProvider = {
36
36
  devDependencies: {},
37
37
  createIndex: getElysiaIndexTemplate,
38
38
  };
39
- //# sourceMappingURL=elysia.js.map
@@ -47,4 +47,3 @@ export const expressBackendProvider = {
47
47
  devDependencies: { "@types/express": "^5.0.0" },
48
48
  createIndex: getExpressIndexTemplate,
49
49
  };
50
- //# sourceMappingURL=express.js.map
@@ -41,4 +41,3 @@ export const fastifyBackendProvider = {
41
41
  devDependencies: {},
42
42
  createIndex: getFastifyIndexTemplate,
43
43
  };
44
- //# sourceMappingURL=fastify.js.map
@@ -35,4 +35,3 @@ export const h3BackendProvider = {
35
35
  devDependencies: {},
36
36
  createIndex: getH3IndexTemplate,
37
37
  };
38
- //# sourceMappingURL=h3.js.map
@@ -45,4 +45,3 @@ export const koaBackendProvider = {
45
45
  devDependencies: { "@types/koa": "^3.0.0" },
46
46
  createIndex: getKoaIndexTemplate,
47
47
  };
48
- //# sourceMappingURL=koa.js.map
@@ -84,4 +84,3 @@ export const mcpBackendProvider = {
84
84
  devDependencies: {},
85
85
  createIndex: getMcpIndexTemplate,
86
86
  };
87
- //# sourceMappingURL=mcp.js.map
@@ -53,4 +53,3 @@ export const nestBackendProvider = {
53
53
  compilerOptions: { experimentalDecorators: true, emitDecoratorMetadata: true },
54
54
  createIndex: getNestIndexTemplate,
55
55
  };
56
- //# sourceMappingURL=nestjs.js.map
@@ -66,4 +66,3 @@ export function resolveBackendFramework(resourceType, frameworkId, language) {
66
66
  }
67
67
  return getBackendFramework(frameworkId);
68
68
  }
69
- //# sourceMappingURL=registry.js.map
@@ -1,2 +1 @@
1
1
  export {};
2
- //# sourceMappingURL=types.js.map
@@ -50,4 +50,3 @@ export const bunBackendProvider = {
50
50
  label: "Bun + Hono",
51
51
  installHint: "bun install",
52
52
  };
53
- //# sourceMappingURL=bun.js.map
@@ -95,4 +95,3 @@ func TestHealth(t *testing.T) {
95
95
  ];
96
96
  },
97
97
  };
98
- //# sourceMappingURL=go.js.map
@@ -86,4 +86,3 @@ def test_health() -> None:
86
86
  ];
87
87
  },
88
88
  };
89
- //# sourceMappingURL=python.js.map
@@ -33,4 +33,3 @@ export function resolveBackendLanguage(resourceType, languageId) {
33
33
  }
34
34
  return getBackendLanguage(languageId);
35
35
  }
36
- //# sourceMappingURL=registry.js.map
@@ -80,4 +80,3 @@ mod tests {
80
80
  ];
81
81
  },
82
82
  };
83
- //# sourceMappingURL=rust.js.map
@@ -1,2 +1 @@
1
1
  export {};
2
- //# sourceMappingURL=types.js.map
package/cli/dist/cli.js CHANGED
@@ -88,4 +88,3 @@ if (unknownHelp) {
88
88
  });
89
89
  }
90
90
  program.parse();
91
- //# sourceMappingURL=cli.js.map
@@ -34,4 +34,3 @@ export function starlarkSection(content, name) {
34
34
  expect(end).toBeGreaterThan(start);
35
35
  return content.slice(start, end + 2);
36
36
  }
37
- //# sourceMappingURL=project-e2e-helpers.js.map
@@ -359,4 +359,3 @@ export const completionCommand = new Command("completion")
359
359
  console.log(completionScript);
360
360
  }
361
361
  });
362
- //# sourceMappingURL=completion.js.map
@@ -9,7 +9,7 @@ import { hasVerdaccioLicense } from "../generator/extension-fetch.js";
9
9
  import { generateMasterConfigs, readProjectConfig, TemplateEngine, verifyMasterConfigs, } from "../generator/template-engine.js";
10
10
  import { isMasterConfigFileName } from "../types/index.js";
11
11
  import { assertValid } from "../utils/command-helpers.js";
12
- import { MASTER_CONFIG_FILES } from "../utils/constants.js";
12
+ import { MASTER_CONFIG_FILES, PROJECT_JSON } from "../utils/constants.js";
13
13
  import { checkPrismaConsistency } from "../utils/doctor-wiring.js";
14
14
  import { errorFactories, requireProjectRoot, runCommand } from "../utils/errors.js";
15
15
  import { writeJsonFile } from "../utils/file-helpers.js";
@@ -19,16 +19,6 @@ import { SERVICE_MANIFEST_SCHEMA_VERSION, validateServiceManifest, } from "../ut
19
19
  import { discoverServiceManifestPaths } from "../utils/services.js";
20
20
  import { evaluateSharedPlatformPostgres } from "../utils/shared-platform-postgres.js";
21
21
  import { validateOptionalInfraService } from "../utils/validation.js";
22
- /**
23
- * Serialize ProjectConfig to JSON-safe value.
24
- * ProjectConfig is guaranteed to be JSON-serializable (all properties are primitive or plain objects).
25
- * This wrapper documents the type relationship that TypeScript cannot infer.
26
- */
27
- function _serializeProjectConfig(config) {
28
- // ProjectConfig has no index signature but is structurally compatible with JsonValue
29
- // eslint-disable-next-line @typescript-eslint/no-unsafe-type-assertion
30
- return config;
31
- }
32
22
  export const configCommand = new Command("config")
33
23
  .description("Manage project configuration and regenerate master files")
34
24
  .addCommand(new Command("regenerate")
@@ -270,7 +260,7 @@ export const configCommand = new Command("config")
270
260
  .addCommand(new Command("edit").description("Open .tdk/project.json in your $EDITOR").action(async () => {
271
261
  await runCommand(async () => {
272
262
  const projectRoot = requireProjectRoot();
273
- const projectJsonPath = join(projectRoot, ".tdk", "project.json");
263
+ const projectJsonPath = join(projectRoot, ".tdk", PROJECT_JSON);
274
264
  if (!existsSync(projectJsonPath)) {
275
265
  throw new Error(".tdk/project.json not found");
276
266
  }
@@ -334,7 +324,7 @@ async function toggleInfraService(service, enabled) {
334
324
  }
335
325
  // Type-safe assignment: service is now narrowed to OptionalInfraKey
336
326
  config.optional_infra[service] = enabled;
337
- const projectJsonPath = join(projectRoot, ".tdk", "project.json");
327
+ const projectJsonPath = join(projectRoot, ".tdk", PROJECT_JSON);
338
328
  // ProjectConfig is guaranteed to be JSON-serializable
339
329
  writeJsonFile(projectJsonPath, config);
340
330
  const action = enabled ? "Enabled" : "Disabled";
@@ -358,4 +348,3 @@ configCommand
358
348
  await toggleInfraService(service, false);
359
349
  });
360
350
  }));
361
- //# sourceMappingURL=config.js.map
@@ -8,7 +8,7 @@ import { Command } from "commander";
8
8
  import { hasVerdaccioLicense } from "../generator/extension-fetch.js";
9
9
  import { DEVCONTAINER_DOCKER_FIX, detectHost, isContainerHost, WEBCONTAINER_DOCS, WEBCONTAINER_UP_MESSAGE, } from "../utils/agent-host.js";
10
10
  import { projectNeedsBun } from "../utils/bun-requirement.js";
11
- import { CONTAINER_RUNTIME_CHECK, MASTER_CONFIG_FILES, REQUIRED_PACKAGE_SCRIPTS, } from "../utils/constants.js";
11
+ import { AUTOGENERATED_DIR, CONTAINER_RUNTIME_CHECK, MASTER_CONFIG_FILES, PACKAGE_JSON, REQUIRED_PACKAGE_SCRIPTS, } from "../utils/constants.js";
12
12
  import { isPathDiscovered, readDiscoveryPaths } from "../utils/discovery-paths.js";
13
13
  import { collectDoctorChecks, createDoctorReport, getDoctorExitCode, } from "../utils/doctor-report.js";
14
14
  import { checkHealthRoutes, checkIngressPorts, checkPrivateNpmRegistry, checkTiltResourceHealth, projectConfigEnablesVerdaccio, summarizeServiceProbes, } from "../utils/doctor-runtime.js";
@@ -525,7 +525,7 @@ const TEMPLATE_COPY_PATTERN = /shared-platform-engineering\/docker-templates\/([
525
525
  function findReferencedTemplateFiles(projectRoot) {
526
526
  const referenced = new Set();
527
527
  for (const resource of discoverResourcesFromRoot(projectRoot)) {
528
- const dir = join(resource.path, ".autogenerated");
528
+ const dir = join(resource.path, AUTOGENERATED_DIR);
529
529
  if (!existsSync(dir))
530
530
  continue;
531
531
  for (const entry of readdirSync(dir)) {
@@ -541,8 +541,8 @@ function findReferencedTemplateFiles(projectRoot) {
541
541
  export function checkGeneratedProjectRuntimeAssets() {
542
542
  const projectRoot = findProjectRoot() ?? process.cwd();
543
543
  const problems = [];
544
- if (!existsSync(join(projectRoot, "package.json"))) {
545
- problems.push("package.json (workspace root manifest)");
544
+ if (!existsSync(join(projectRoot, PACKAGE_JSON))) {
545
+ problems.push(`${PACKAGE_JSON} (workspace root manifest)`);
546
546
  }
547
547
  const templateDir = join(projectRoot, "shared-platform-engineering", "docker-templates");
548
548
  let referenced = [];
@@ -576,7 +576,7 @@ function checkStartupScripts() {
576
576
  const resources = discoverResourcesFromRoot(projectRoot);
577
577
  const problems = [];
578
578
  for (const resource of resources) {
579
- const packageJsonPath = join(resource.path, "package.json");
579
+ const packageJsonPath = join(resource.path, PACKAGE_JSON);
580
580
  if (!existsSync(packageJsonPath)) {
581
581
  continue;
582
582
  }
@@ -684,8 +684,8 @@ export function checkTypeScriptTypeDependencies() {
684
684
  const problems = [];
685
685
  const missingPackages = new Set();
686
686
  for (const resource of resources) {
687
- const packageJsonPath = join(resource.path, "package.json");
688
- const dockerTsconfigPath = join(resource.path, ".autogenerated", "tsconfig.docker.autogenerated.json");
687
+ const packageJsonPath = join(resource.path, PACKAGE_JSON);
688
+ const dockerTsconfigPath = join(resource.path, AUTOGENERATED_DIR, "tsconfig.docker.autogenerated.json");
689
689
  if (!existsSync(packageJsonPath) || !existsSync(dockerTsconfigPath)) {
690
690
  continue;
691
691
  }
@@ -769,14 +769,14 @@ export function checkFrontendDockerPreflight() {
769
769
  if (!existsSync(join(resource.path, "public"))) {
770
770
  problems.push(`${resource.name}: no public/ folder, but the Docker build copies it. Create it: mkdir -p ${normalize(relative(projectRoot, join(resource.path, "public")))} && touch ${normalize(relative(projectRoot, join(resource.path, "public", ".gitkeep")))}`);
771
771
  }
772
- const dockerfilePath = join(resource.path, ".autogenerated", "Dockerfile.app.autogenerated");
773
- const dockerTsconfigPath = join(resource.path, ".autogenerated", "tsconfig.docker.autogenerated.json");
772
+ const dockerfilePath = join(resource.path, AUTOGENERATED_DIR, "Dockerfile.app.autogenerated");
773
+ const dockerTsconfigPath = join(resource.path, AUTOGENERATED_DIR, "tsconfig.docker.autogenerated.json");
774
774
  if (existsSync(dockerfilePath)) {
775
775
  const dockerfile = readFileSync(dockerfilePath, "utf-8");
776
776
  const exposesNginxPort = /\bEXPOSE\s+80\b/.test(dockerfile);
777
777
  const stack = resource.config?.stack;
778
778
  const composePath = stack
779
- ? join(projectRoot, "services", stack, ".autogenerated", "docker-compose.app.autogenerated.yml")
779
+ ? join(projectRoot, "services", stack, AUTOGENERATED_DIR, "docker-compose.app.autogenerated.yml")
780
780
  : "";
781
781
  if (exposesNginxPort && composePath && existsSync(composePath)) {
782
782
  const compose = readFileSync(composePath, "utf-8");
@@ -1152,4 +1152,3 @@ export const doctorCommand = new Command("doctor")
1152
1152
  if (exitCode !== 0)
1153
1153
  process.exit(exitCode);
1154
1154
  });
1155
- //# sourceMappingURL=doctor.js.map
@@ -107,4 +107,3 @@ export const downCommand = new Command("down")
107
107
  });
108
108
  });
109
109
  });
110
- //# sourceMappingURL=down.js.map
@@ -105,4 +105,3 @@ export const ejectCommand = new Command("eject")
105
105
  console.log("Read EJECTED.md");
106
106
  });
107
107
  });
108
- //# sourceMappingURL=eject.js.map
@@ -142,4 +142,3 @@ export function showHelp() {
142
142
  console.log(chalk.gray(` GitHub: ${chalk.cyan("https://github.com/tdk-landscape/tdk-cli-core")}`));
143
143
  console.log();
144
144
  }
145
- //# sourceMappingURL=help.js.map
@@ -38,4 +38,3 @@ export const importCommand = new Command("import")
38
38
  .action(async (args) => {
39
39
  process.exitCode = await runImport(args);
40
40
  });
41
- //# sourceMappingURL=import.js.map
@@ -117,4 +117,3 @@ export const logsCommand = new Command("logs")
117
117
  };
118
118
  await runCommand(action);
119
119
  });
120
- //# sourceMappingURL=logs.js.map
@@ -100,4 +100,3 @@ export const maintainersCommand = new Command("maintainers")
100
100
  (exitCode === 0 ? console.log : console.error)(output);
101
101
  process.exitCode = exitCode;
102
102
  }));
103
- //# sourceMappingURL=maintainers.js.map
@@ -23,4 +23,3 @@ export const mcpCommand = new Command("mcp")
23
23
  await new Promise((resolve) => lines.once("close", resolve));
24
24
  await Promise.allSettled(pending);
25
25
  });
26
- //# sourceMappingURL=mcp.js.map
@@ -96,7 +96,6 @@ function determineDefaultDomain() {
96
96
  const firstDomain = domainList[0];
97
97
  const localhostMatch = firstDomain.match(/([\w-]+)\.localhost$/);
98
98
  if (localhostMatch) {
99
- const _prefix = localhostMatch[1];
100
99
  // If it looks like a service domain, try common project names
101
100
  const commonProjects = ["tdk", "project", "app", "api", "myapp"];
102
101
  for (const project of commonProjects) {
@@ -305,4 +304,3 @@ export const networksCommand = new Command("networks")
305
304
  }
306
305
  await action();
307
306
  });
308
- //# sourceMappingURL=networks.js.map
@@ -8,7 +8,7 @@ import { fileURLToPath } from "node:url";
8
8
  import chalk from "chalk";
9
9
  import { Command } from "commander";
10
10
  import { generateMasterConfigs, readProjectConfig } from "../generator/template-engine.js";
11
- import { MASTER_CONFIG_FILES } from "../utils/constants.js";
11
+ import { MASTER_CONFIG_FILES, PROJECT_JSON } from "../utils/constants.js";
12
12
  import { completeEnvFile, ensureEnvFile, validateEnvFile } from "../utils/env-validator.js";
13
13
  import { errorFactories, runCommand, showErrorAndExit } from "../utils/errors.js";
14
14
  import { ensureDirectory, ensureGitignore, writeJsonFile } from "../utils/file-helpers.js";
@@ -58,7 +58,7 @@ function syncDiscoveredStacksToPreAlpha(projectConfig, discoveredStacks) {
58
58
  * `tdk up` without re-running `tdk project`. Returns the stacks it enabled.
59
59
  */
60
60
  export function enableDiscoveredStacks(projectRoot) {
61
- const projectJsonPath = join(projectRoot, ".tdk", "project.json");
61
+ const projectJsonPath = join(projectRoot, ".tdk", PROJECT_JSON);
62
62
  if (!existsSync(projectJsonPath))
63
63
  return [];
64
64
  const projectConfig = readProjectConfig(projectRoot);
@@ -197,7 +197,7 @@ export const projectCommand = new Command("project")
197
197
  showDetail(`Location: ${projectRoot}\n`, 0);
198
198
  }
199
199
  const tdkDir = join(projectRoot, ".tdk");
200
- const projectJsonPath = join(tdkDir, "project.json");
200
+ const projectJsonPath = join(tdkDir, PROJECT_JSON);
201
201
  if (options.check) {
202
202
  const allFilesExist = MASTER_CONFIG_FILES.every((f) => existsSync(join(projectRoot, ".tdk", ".tdk-out", f)));
203
203
  const projectJsonExists = existsSync(projectJsonPath);
@@ -431,4 +431,3 @@ export const projectCommand = new Command("project")
431
431
  showDetail("\nAfter editing .tdk/project.json, run `tdk config regenerate`.", 0);
432
432
  });
433
433
  });
434
- //# sourceMappingURL=project.js.map
@@ -101,4 +101,3 @@ export const projectsCommand = new Command("projects")
101
101
  }
102
102
  await runCommand(action);
103
103
  });
104
- //# sourceMappingURL=projects.js.map
@@ -12,7 +12,7 @@ import { hasDddLicense } from "../generator/extension-fetch.js";
12
12
  import { getDockerfileTemplate, getTestTemplate, getWorkerIndexTemplate, } from "../generator/resource-templates.js";
13
13
  import { CREATABLE_RESOURCE_TYPES } from "../types/index.js";
14
14
  import { assertValid, confirmOrCancel } from "../utils/command-helpers.js";
15
- import { BRING_YOUR_OWN_TYPE, PORT_RANGES, SERVICE_JSON } from "../utils/constants.js";
15
+ import { AUTOGENERATED_DIR, BRING_YOUR_OWN_TYPE, PACKAGE_JSON, PORT_RANGES, SERVICE_JSON, } from "../utils/constants.js";
16
16
  import { chooseResourcePath, isPathDiscovered, readDiscoveryPaths, } from "../utils/discovery-paths.js";
17
17
  import { errorFactories, requireProjectRoot, runCommand, TdkError } from "../utils/errors.js";
18
18
  import { writeFilesWithProgress } from "../utils/file-helpers.js";
@@ -165,15 +165,15 @@ export function createPackageJson(name, type, frameworkId, prismaEnabled = false
165
165
  scripts: {
166
166
  ...(isFrontend
167
167
  ? {
168
- predev: requireGeneratedViteConfig(".autogenerated/vite.config.frontend.autogenerated.ts"),
169
- prebuild: requireGeneratedViteConfig(".autogenerated/vite.config.build.autogenerated.ts"),
168
+ predev: requireGeneratedViteConfig(`${AUTOGENERATED_DIR}/vite.config.frontend.autogenerated.ts`),
169
+ prebuild: requireGeneratedViteConfig(`${AUTOGENERATED_DIR}/vite.config.build.autogenerated.ts`),
170
170
  }
171
171
  : {}),
172
172
  dev: isFrontend
173
- ? "vite --config .autogenerated/vite.config.frontend.autogenerated.ts"
173
+ ? `vite --config ${AUTOGENERATED_DIR}/vite.config.frontend.autogenerated.ts`
174
174
  : "bun run --watch src/index.ts",
175
175
  build: isFrontend
176
- ? "tsc && vite build --config .autogenerated/vite.config.build.autogenerated.ts"
176
+ ? `tsc && vite build --config ${AUTOGENERATED_DIR}/vite.config.build.autogenerated.ts`
177
177
  : "tsc",
178
178
  // Backends and workers run `start` in their production image; doctor checks for it.
179
179
  ...(isFrontend ? {} : { start: "bun run dist/index.js" }),
@@ -201,7 +201,9 @@ export function createPackageJson(name, type, frameworkId, prismaEnabled = false
201
201
  typescript: "^7.0.2",
202
202
  vitest: "^5.0.0",
203
203
  "@biomejs/biome": "^2.5.13",
204
- ...(isFrontend ? { vite: "^5.0.0" } : {}),
204
+ // vitest 5 peers on vite ^6.4.0 || ^7 || ^8; vite 5 makes `vitest run` fail at startup with
205
+ // ERR_PACKAGE_PATH_NOT_EXPORTED ('./module-runner'), in every resource once it is hoisted.
206
+ ...(isFrontend ? { vite: "^6.4.1" } : {}),
205
207
  ...(framework?.devDependencies ?? {}),
206
208
  ...(backendFramework?.devDependencies ?? {}),
207
209
  },
@@ -620,7 +622,7 @@ This file contains the resource configuration for TDK.
620
622
  },
621
623
  {
622
624
  type: "json",
623
- filename: "package.json",
625
+ filename: PACKAGE_JSON,
624
626
  content: packageJson,
625
627
  description: "Generating package.json",
626
628
  emoji: "📦",
@@ -694,7 +696,7 @@ This file contains the resource configuration for TDK.
694
696
  !(owned.has(task.filename) ||
695
697
  task.filename === "Dockerfile" ||
696
698
  task.filename === "src/index.ts" ||
697
- task.filename === "package.json" ||
699
+ task.filename === PACKAGE_JSON ||
698
700
  task.filename === "tsconfig.json" ||
699
701
  task.filename.endsWith(".test.ts")));
700
702
  tasks.length = 0;
@@ -736,7 +738,7 @@ This file contains the resource configuration for TDK.
736
738
  },
737
739
  {
738
740
  type: "json",
739
- filename: "package.json",
741
+ filename: PACKAGE_JSON,
740
742
  content: migratorPackage,
741
743
  description: "Generating Prisma migrator package",
742
744
  emoji: "📦",
@@ -793,4 +795,3 @@ This file contains the resource configuration for TDK.
793
795
  console.log(chalk.gray(` tdk up ${stackName}`));
794
796
  });
795
797
  });
796
- //# sourceMappingURL=resource.js.map
@@ -125,4 +125,3 @@ export const resourcesCommand = new Command("resources")
125
125
  }
126
126
  await runCommand(action);
127
127
  });
128
- //# sourceMappingURL=resources.js.map
@@ -73,4 +73,3 @@ export const runtimeCommand = new Command("runtime")
73
73
  if (!ok)
74
74
  process.exitCode = 1;
75
75
  });
76
- //# sourceMappingURL=runtime.js.map
@@ -170,4 +170,3 @@ export const stackCommand = new Command("stack")
170
170
  showDetail(`\nYou can now run: tdk up ${targetStack}`, 0);
171
171
  });
172
172
  });
173
- //# sourceMappingURL=stack.js.map
@@ -69,4 +69,3 @@ export const stacksCommand = new Command("stacks")
69
69
  }
70
70
  await runCommand(action);
71
71
  });
72
- //# sourceMappingURL=stacks.js.map
@@ -196,4 +196,3 @@ export const statusCommand = new Command("status")
196
196
  }
197
197
  await runCommand(action);
198
198
  });
199
- //# sourceMappingURL=status.js.map
@@ -6,7 +6,7 @@ import { Box, render, Text, useApp, useInput, useStdin, useStdout } from "ink";
6
6
  import { useCallback, useEffect, useMemo, useRef, useState } from "react";
7
7
  import { DetailPanel, FileTree, ResourceSelectInput, ResourceTable, ServiceIssues, TabBar, TUIHeader, } from "../components/index.js";
8
8
  import { TABS } from "../components/TabBar.js";
9
- import { createTUITheme, TUIThemeContext, useTUITheme } from "../components/ui-theme.js";
9
+ import { createTUITheme, sectionTitle, TUIThemeContext, useTUITheme, } from "../components/ui-theme.js";
10
10
  import { errorFactories, requireProjectRoot } from "../utils/errors.js";
11
11
  import { findProjectRoot, getPackageVersion } from "../utils/paths.js";
12
12
  import { describeSearch } from "../utils/search-status.js";
@@ -349,7 +349,7 @@ export const TUIApp = ({ animated = true }) => {
349
349
  const sgrMatch = str.match(/\x1b\[<(\d+);(\d+);(\d+)([Mm])/);
350
350
  if (sgrMatch) {
351
351
  const btn = parseInt(sgrMatch[1], 10);
352
- const _x = parseInt(sgrMatch[2], 10);
352
+ // sgrMatch[2] is the x coordinate, which the handler does not use
353
353
  const y = parseInt(sgrMatch[3], 10);
354
354
  const release = sgrMatch[4] === "m";
355
355
  // Check if it's a left click (btn & 0b11 == 0 means left button)
@@ -565,21 +565,21 @@ export const TUIApp = ({ animated = true }) => {
565
565
  }
566
566
  const header = (_jsxs(_Fragment, { children: [_jsx(TUIHeader, { projectRoot: projectRoot, resourceCount: services.length, terminalWidth: terminalWidth, version: getPackageVersion() }), _jsx(Box, { paddingX: 1, children: _jsx(Text, { color: theme.muted, children: (theme.ascii ? "-" : "\u2500").repeat(getTerminalRuleWidth(terminalWidth)) }) })] }));
567
567
  return (_jsxs(Box, { flexDirection: "column", height: stdout.rows || 24, children: [header, isSearching && (_jsxs(Box, { paddingX: 1, height: 1, children: [_jsxs(Text, { color: theme.warning, children: ["Search: ", searchQuery, "_"] }), searchStatus && (_jsx(Text, { color: theme.muted, dimColor: theme.dimMuted, children: ` ${searchStatus.summary}` }))] })), searchStatus?.emptyMessage && (_jsx(Box, { paddingX: 1, height: 1, children: _jsx(Text, { color: theme.muted, children: searchStatus.emptyMessage }) })), !isSearching && message && (_jsx(Box, { paddingX: 1, height: 1, children: _jsxs(Text, { color: theme.accent, children: [theme.bannerStart, " ", message, " ", theme.bannerEnd] }) })), !isSearching && !message && showTooltips && !showHelp && (_jsx(Box, { paddingX: 1, height: 1, children: _jsx(Text, { color: theme.muted, dimColor: theme.dimMuted, children: createHelpHint(activeTab, selectedStack, selectedService, showEnabledOnly, theme.ascii) }) })), showHelp && (_jsx(Box, { paddingX: 1, flexGrow: 1, children: _jsx(HelpPanel, { onClose: () => setShowHelp(false) }) })), !showHelp && (_jsxs(_Fragment, { children: [_jsx(Box, { marginTop: 1, children: _jsx(TabBar, { activeTab: activeTab, onTabChange: setActiveTab, terminalWidth: terminalWidth }) }), _jsxs(Box, { flexDirection: "row", paddingX: 1, flexGrow: 1, children: [_jsxs(Box, { flexDirection: "column", flexGrow: 1, width: mainPanelWidth, children: [activeTab === "overview" &&
568
- (services.length === 0 ? (_jsx(EmptyState, { message: message })) : (_jsxs(_Fragment, { children: [_jsx(Box, { marginBottom: 1, children: _jsx(Text, { bold: true, color: theme.muted, children: "Stacks" }) }), _jsx(Box, { marginTop: 1, flexGrow: 1, children: _jsx(ResourceSelectInput, { items: items, onSelect: handleSelect, highlightedIndex: highlightedIndex, isActive: !isSearching, maxVisibleItems: pageSize, width: mainPanelWidth, onLayout: handleListLayout }) })] }))), activeTab === "resources" && (_jsxs(_Fragment, { children: [_jsx(Box, { marginBottom: 1, children: _jsx(Text, { bold: true, color: theme.muted, children: theme.ascii ? "[ Resources ]" : "┌─ Resources ─" }) }), selectedStackData ? (_jsxs(_Fragment, { children: [_jsxs(Text, { color: theme.muted, children: ["Stack: ", selectedStackData.stack.name] }), _jsxs(Box, { marginTop: 1, flexDirection: "column", children: [_jsx(ResourceTable, { resources: selectedStackData.metadata.resources, maxWidth: terminalWidth - (showSidebar ? 50 : 10) }), _jsx(ServiceIssues, { resources: selectedStackData.metadata.resources })] })] })) : (_jsxs(_Fragment, { children: [_jsx(Text, { color: theme.muted, children: "Select a stack to view resources" }), _jsx(Box, { marginTop: 1, children: _jsx(ResourceSelectInput, { items: items, onSelect: handleSelect, highlightedIndex: highlightedIndex, isActive: !isSearching, maxVisibleItems: pageSize, width: mainPanelWidth, onLayout: handleListLayout }) })] }))] })), activeTab === "files" && (_jsxs(_Fragment, { children: [_jsx(Box, { marginBottom: 1, children: _jsx(Text, { bold: true, color: theme.muted, children: theme.ascii ? "[ Autogenerated Files ]" : "┌─ Autogenerated Files ─" }) }), selectedServiceData ? (_jsxs(_Fragment, { children: [_jsxs(Text, { color: theme.muted, children: ["Service: ", selectedServiceData.service.name] }), _jsx(Box, { marginTop: 1, children: _jsx(FileTree, { nodes: fileTreeNodes, selectedPath: selectedFile || undefined }) })] })) : (_jsxs(_Fragment, { children: [_jsx(Text, { color: theme.muted, children: "Select a service to view files" }), _jsx(Box, { marginTop: 1, children: _jsx(ResourceSelectInput, { items: items, onSelect: handleSelect, highlightedIndex: highlightedIndex, isActive: !isSearching, maxVisibleItems: pageSize, width: mainPanelWidth, onLayout: handleListLayout }) })] }))] })), activeTab === "events" && (_jsxs(Box, { flexDirection: "column", flexGrow: 1, children: [_jsx(Box, { marginBottom: 1, children: _jsx(Text, { bold: true, color: theme.muted, children: theme.ascii ? "[ Event Timeline ]" : "┌─ Event Timeline ─" }) }), (eventLoadState === "idle" || eventLoadState === "loading") && (_jsx(Text, { color: theme.muted, children: "Loading Tilt events..." })), eventLoadState === "unavailable" && (_jsxs(Box, { flexDirection: "column", children: [_jsx(Text, { color: theme.warning, children: "Tilt is not running or its UI is unreachable." }), _jsx(Text, { color: theme.muted, children: "Start the stack with tdk up, then press [r] to retry." })] })), eventLoadState === "error" && (_jsxs(Box, { flexDirection: "column", children: [_jsx(Text, { color: theme.error, children: "Could not load Tilt events." }), _jsx(Text, { color: theme.muted, children: formatEventDetails(eventLoadError ?? "Unknown Tilt error", mainPanelWidth) }), _jsx(Text, { color: theme.muted, children: "Press [r] to retry." })] })), eventLoadState === "ready" && (_jsxs(_Fragment, { children: [eventSnapshot && eventSnapshot.resources.length > 0 && (_jsxs(Box, { flexDirection: "column", marginBottom: 1, children: [_jsx(Text, { bold: true, color: theme.muted, children: "Current resources" }), eventSnapshot.resources.slice(0, 12).map((resource) => (_jsxs(Text, { color: theme.accent, children: [resource.name, ": ", formatResourceStatus(resource)] }, resource.name))), eventSnapshot.resources.length > 12 && (_jsx(Text, { color: theme.muted, children: "Showing first 12 resources" }))] })), _jsx(Text, { bold: true, color: theme.muted, children: "Recent events" }), eventSnapshot && eventSnapshot.events.length > 20 && (_jsx(Text, { color: theme.muted, children: "Showing first 20 events" })), eventSnapshot?.events.length ? (_jsx(Box, { flexDirection: "column", marginTop: 1, children: eventSnapshot.events.slice(0, 20).map((event) => (_jsxs(Box, { flexDirection: "column", marginBottom: 1, children: [_jsxs(Text, { color: event.kind === "failed"
568
+ (services.length === 0 ? (_jsx(EmptyState, { message: message })) : (_jsxs(_Fragment, { children: [_jsx(Box, { marginBottom: 1, children: _jsx(Text, { bold: true, color: theme.muted, children: "Stacks" }) }), _jsx(Box, { marginTop: 1, flexGrow: 1, children: _jsx(ResourceSelectInput, { items: items, onSelect: handleSelect, highlightedIndex: highlightedIndex, isActive: !isSearching, maxVisibleItems: pageSize, width: mainPanelWidth, onLayout: handleListLayout }) })] }))), activeTab === "resources" && (_jsxs(_Fragment, { children: [_jsx(Box, { marginBottom: 1, children: _jsx(Text, { bold: true, color: theme.muted, children: sectionTitle(theme, "Resources") }) }), selectedStackData ? (_jsxs(_Fragment, { children: [_jsxs(Text, { color: theme.muted, children: ["Stack: ", selectedStackData.stack.name] }), _jsxs(Box, { marginTop: 1, flexDirection: "column", children: [_jsx(ResourceTable, { resources: selectedStackData.metadata.resources, maxWidth: terminalWidth - (showSidebar ? 50 : 10) }), _jsx(ServiceIssues, { resources: selectedStackData.metadata.resources })] })] })) : (_jsxs(_Fragment, { children: [_jsx(Text, { color: theme.muted, children: "Select a stack to view resources" }), _jsx(Box, { marginTop: 1, children: _jsx(ResourceSelectInput, { items: items, onSelect: handleSelect, highlightedIndex: highlightedIndex, isActive: !isSearching, maxVisibleItems: pageSize, width: mainPanelWidth, onLayout: handleListLayout }) })] }))] })), activeTab === "files" && (_jsxs(_Fragment, { children: [_jsx(Box, { marginBottom: 1, children: _jsx(Text, { bold: true, color: theme.muted, children: sectionTitle(theme, "Autogenerated Files") }) }), selectedServiceData ? (_jsxs(_Fragment, { children: [_jsxs(Text, { color: theme.muted, children: ["Service: ", selectedServiceData.service.name] }), _jsx(Box, { marginTop: 1, children: _jsx(FileTree, { nodes: fileTreeNodes, selectedPath: selectedFile || undefined }) })] })) : (_jsxs(_Fragment, { children: [_jsx(Text, { color: theme.muted, children: "Select a service to view files" }), _jsx(Box, { marginTop: 1, children: _jsx(ResourceSelectInput, { items: items, onSelect: handleSelect, highlightedIndex: highlightedIndex, isActive: !isSearching, maxVisibleItems: pageSize, width: mainPanelWidth, onLayout: handleListLayout }) })] }))] })), activeTab === "events" && (_jsxs(Box, { flexDirection: "column", flexGrow: 1, children: [_jsx(Box, { marginBottom: 1, children: _jsx(Text, { bold: true, color: theme.muted, children: sectionTitle(theme, "Event Timeline") }) }), (eventLoadState === "idle" || eventLoadState === "loading") && (_jsx(Text, { color: theme.muted, children: "Loading Tilt events..." })), eventLoadState === "unavailable" && (_jsxs(Box, { flexDirection: "column", children: [_jsx(Text, { color: theme.warning, children: "Tilt is not running or its UI is unreachable." }), _jsx(Text, { color: theme.muted, children: "Start the stack with tdk up, then press [r] to retry." })] })), eventLoadState === "error" && (_jsxs(Box, { flexDirection: "column", children: [_jsx(Text, { color: theme.error, children: "Could not load Tilt events." }), _jsx(Text, { color: theme.muted, children: formatEventDetails(eventLoadError ?? "Unknown Tilt error", mainPanelWidth) }), _jsx(Text, { color: theme.muted, children: "Press [r] to retry." })] })), eventLoadState === "ready" && (_jsxs(_Fragment, { children: [eventSnapshot && eventSnapshot.resources.length > 0 && (_jsxs(Box, { flexDirection: "column", marginBottom: 1, children: [_jsx(Text, { bold: true, color: theme.muted, children: "Current resources" }), eventSnapshot.resources.slice(0, 12).map((resource) => (_jsxs(Text, { color: theme.accent, children: [resource.name, ": ", formatResourceStatus(resource)] }, resource.name))), eventSnapshot.resources.length > 12 && (_jsx(Text, { color: theme.muted, children: "Showing first 12 resources" }))] })), _jsx(Text, { bold: true, color: theme.muted, children: "Recent events" }), eventSnapshot && eventSnapshot.events.length > 20 && (_jsx(Text, { color: theme.muted, children: "Showing first 20 events" })), eventSnapshot?.events.length ? (_jsx(Box, { flexDirection: "column", marginTop: 1, children: eventSnapshot.events.slice(0, 20).map((event) => (_jsxs(Box, { flexDirection: "column", marginBottom: 1, children: [_jsxs(Text, { color: event.kind === "failed"
569
569
  ? theme.error
570
570
  : event.kind === "warning"
571
571
  ? theme.warning
572
572
  : event.kind === "running"
573
573
  ? theme.info
574
- : theme.success, children: [formatEventTime(event.occurredAt), " ", event.resourceName, " ", event.title] }), event.details && (_jsx(Text, { color: theme.muted, children: formatEventDetails(event.details, mainPanelWidth) }))] }, event.id))) })) : (_jsx(Text, { color: theme.muted, children: "No recent build events are available from Tilt yet." }))] }))] })), activeTab === "config" && (_jsxs(_Fragment, { children: [_jsx(Box, { marginBottom: 1, children: _jsx(Text, { bold: true, color: theme.muted, children: theme.ascii ? "[ Configuration ]" : "┌─ Configuration ─" }) }), selectedServiceData ? (_jsxs(Box, { marginTop: 1, flexDirection: "column", children: [_jsx(Text, { color: theme.accent, children: selectedServiceData.service.configPath }), _jsx(Box, { marginTop: 1, ...(theme.ascii
574
+ : theme.success, children: [formatEventTime(event.occurredAt), " ", event.resourceName, " ", event.title] }), event.details && (_jsx(Text, { color: theme.muted, children: formatEventDetails(event.details, mainPanelWidth) }))] }, event.id))) })) : (_jsx(Text, { color: theme.muted, children: "No recent build events are available from Tilt yet." }))] }))] })), activeTab === "config" && (_jsxs(_Fragment, { children: [_jsx(Box, { marginBottom: 1, children: _jsx(Text, { bold: true, color: theme.muted, children: sectionTitle(theme, "Configuration") }) }), selectedServiceData ? (_jsxs(Box, { marginTop: 1, flexDirection: "column", children: [_jsx(Text, { color: theme.accent, children: selectedServiceData.service.configPath }), _jsx(Box, { marginTop: 1, ...(theme.ascii
575
575
  ? {}
576
- : { borderStyle: "single", borderColor: theme.border }), paddingX: 1, children: _jsx(Text, { color: theme.muted, wrap: "wrap", children: JSON.stringify(selectedServiceData.service.config, null, 2).slice(0, 1000) }) })] })) : (_jsxs(_Fragment, { children: [_jsx(Text, { color: theme.muted, children: "Select a service to view configuration" }), _jsx(Box, { marginTop: 1, children: _jsx(ResourceSelectInput, { items: items, onSelect: handleSelect, highlightedIndex: highlightedIndex, isActive: !isSearching, maxVisibleItems: pageSize, width: mainPanelWidth, onLayout: handleListLayout }) })] }))] }))] }), showSidebar && (_jsx(Box, { marginLeft: 2, children: _jsx(DetailPanel, { stack: selectedStackData?.stack || null, service: selectedServiceData?.service || null, stackMetadata: selectedStackData?.metadata || null, visible: !!selectedStack || !!selectedService }) }))] }), _jsxs(Box, { ...(theme.ascii ? {} : { borderStyle: "single", borderColor: theme.border }), paddingX: 1, height: 3, flexDirection: "column", marginTop: 1, children: [_jsxs(Box, { justifyContent: "space-between", children: [_jsxs(Text, { color: theme.accent, bold: true, children: [theme.bannerStart, " ", activeTab] }), _jsxs(Text, { color: theme.success, children: [theme.ascii ? "[+]" : "\u25cf", " ", services.filter((s) => s.stack).length, " in stack"] }), _jsxs(Text, { color: theme.warning, children: [theme.ascii ? "-" : "\u25cb", " ", services.filter((s) => !s.stack).length, " no stack"] })] }), _jsxs(Box, { justifyContent: "space-between", children: [_jsxs(Text, { color: theme.muted, children: ["Stacks: ", stacks.length] }), _jsxs(Text, { color: theme.muted, children: ["Services: ", services.length] }), _jsxs(Text, { color: theme.muted, children: [theme.ascii ? "Mouse" : "🖱️", " ", mouseEnabled ? "ON" : "OFF", theme.ascii ? " | " : " \u2502 ", theme.ascii ? "Info" : "ℹ️", " ", showTooltips ? "ON" : "OFF", theme.ascii ? " | " : " \u2502 ", _jsx(Text, { color: showEnabledOnly ? theme.success : theme.warning, children: showEnabledOnly
576
+ : { borderStyle: "single", borderColor: theme.border }), paddingX: 1, children: _jsx(Text, { color: theme.muted, wrap: "wrap", children: JSON.stringify(selectedServiceData.service.config, null, 2).slice(0, 1000) }) })] })) : (_jsxs(_Fragment, { children: [_jsx(Text, { color: theme.muted, children: "Select a service to view configuration" }), _jsx(Box, { marginTop: 1, children: _jsx(ResourceSelectInput, { items: items, onSelect: handleSelect, highlightedIndex: highlightedIndex, isActive: !isSearching, maxVisibleItems: pageSize, width: mainPanelWidth, onLayout: handleListLayout }) })] }))] }))] }), showSidebar && (_jsx(Box, { marginLeft: 2, children: _jsx(DetailPanel, { stack: selectedStackData?.stack || null, service: selectedServiceData?.service || null, stackMetadata: selectedStackData?.metadata || null, visible: !!selectedStack || !!selectedService }) }))] }), _jsxs(Box, { ...(theme.ascii ? {} : { borderStyle: "single", borderColor: theme.border }), paddingX: 1, height: 3, flexDirection: "column", marginTop: 1, children: [_jsxs(Box, { justifyContent: "space-between", children: [_jsxs(Text, { color: theme.accent, bold: true, children: [theme.bannerStart, " ", activeTab] }), _jsxs(Text, { color: theme.success, children: [theme.ascii ? "[+]" : "\u25cf", " ", services.filter((s) => s.stack).length, " in stack"] }), _jsxs(Text, { color: theme.warning, children: [theme.ascii ? "-" : "\u25cb", " ", services.filter((s) => !s.stack).length, " no stack"] })] }), _jsxs(Box, { justifyContent: "space-between", children: [_jsxs(Text, { color: theme.muted, children: ["Stacks: ", stacks.length] }), _jsxs(Text, { color: theme.muted, children: ["Services: ", services.length] }), _jsxs(Text, { color: theme.muted, children: [theme.ascii ? "Mouse" : "🖱️", " ", mouseEnabled ? "ON" : "OFF", theme.separator, theme.ascii ? "Info" : "ℹ️", " ", showTooltips ? "ON" : "OFF", theme.separator, _jsx(Text, { color: showEnabledOnly ? theme.success : theme.warning, children: showEnabledOnly
577
577
  ? theme.ascii
578
578
  ? "[+] enabled"
579
579
  : "\u2713 enabled"
580
580
  : theme.ascii
581
581
  ? "[+] all"
582
- : "\u2713 all" }), theme.ascii ? " | " : " \u2502 ", "[?] Help", theme.ascii ? " | " : " \u2502 ", "[q] Quit"] })] })] })] }))] }));
582
+ : "\u2713 all" }), theme.separator, formatUiKeyHint("help", "Help", theme.ascii), theme.separator, formatUiKeyHint("quit", "Quit", theme.ascii)] })] })] })] }))] }));
583
583
  };
584
584
  /** Compose footer guidance for the current tab and terminal character set. */
585
585
  function createHelpHint(activeTab, selectedStack, selectedService, showEnabledOnly, ascii) {
@@ -589,7 +589,7 @@ function createHelpHint(activeTab, selectedStack, selectedService, showEnabledOn
589
589
  const cycleTabs = formatUiKeyHint("cycle-tabs", "Tabs", ascii);
590
590
  if (activeTab === "overview") {
591
591
  const introduction = selectedStack
592
- ? 'Stack "' + selectedStack + '" selected. ' + formatUiKeyHint("select", "view", ascii)
592
+ ? `Stack "${selectedStack}" selected. ${formatUiKeyHint("select", "view", ascii)}`
593
593
  : formatUiKeyHint("list-navigation", "Navigate", ascii);
594
594
  const controls = selectedStack
595
595
  ? [formatUiKeyHint("back", "back", ascii), ...common]
@@ -605,11 +605,7 @@ function createHelpHint(activeTab, selectedStack, selectedService, showEnabledOn
605
605
  ].join(separator);
606
606
  }
607
607
  if (activeTab === "files" && selectedService) {
608
- return [
609
- 'Service "' + selectedService + '"',
610
- formatUiKeyHint("back", "Back", ascii),
611
- ...common,
612
- ].join(separator);
608
+ return [`Service "${selectedService}"`, formatUiKeyHint("back", "Back", ascii), ...common].join(separator);
613
609
  }
614
610
  if (activeTab === "files") {
615
611
  return ["Select service to view files", ...common].join(separator);
@@ -650,4 +646,3 @@ export const uiCommand = new Command("ui")
650
646
  alternateScreen: true,
651
647
  });
652
648
  });
653
- //# sourceMappingURL=ui.js.map
@@ -298,22 +298,22 @@ export const upCommand = new Command("up")
298
298
  const serviceNames = servicesToStart.map((s) => s.name);
299
299
  if (!options.quiet) {
300
300
  console.log(chalk.blue(`${options.dryRun ? "Would start" : "Starting"} ${formatCount(serviceNames.length, "service")} from ${stackDescription}...`));
301
- serviceNames.forEach((name) => {
301
+ for (const name of serviceNames) {
302
302
  console.log(chalk.gray(` - ${name}`));
303
- });
303
+ }
304
304
  const { appBase, apiBase } = resolveSubdomainBases(hostPortPlan.ingressHttp);
305
305
  const frontends = servicesToStart.filter((s) => s.config?.appType === "frontend");
306
306
  const backends = servicesToStart.filter((s) => isApiServiceType(s.config?.appType));
307
307
  if (frontends.length > 0) {
308
308
  console.log(chalk.blue("\n🌍 Frontend URLs:"));
309
- frontends.forEach((svc) => {
309
+ for (const svc of frontends) {
310
310
  const basePath = svc.config?.basePath ?? `/${svc.name}`;
311
311
  console.log(chalk.gray(` - ${svc.name}: ${appBase}${chalk.cyan(appendHealthPath(basePath))}`));
312
- });
312
+ }
313
313
  }
314
314
  if (backends.length > 0) {
315
315
  console.log(chalk.blue("\n🔧 Backend API URLs:"));
316
- backends.forEach((svc) => {
316
+ for (const svc of backends) {
317
317
  const servicePathName = svc.name.replace(/-api$/, "");
318
318
  const apiPath = svc.config?.apiPath ?? `/api/${servicePathName}`;
319
319
  const sablier = svc.config?.sablier;
@@ -321,7 +321,7 @@ export const upCommand = new Command("up")
321
321
  ? chalk.dim(" (deferred — starts on first request)")
322
322
  : "";
323
323
  console.log(chalk.gray(` - ${svc.name}: ${apiBase}${chalk.cyan(appendHealthPath(apiPath))}${deferredTag}`));
324
- });
324
+ }
325
325
  }
326
326
  }
327
327
  const focusTargets = options.only ?? (stackName ? [stackName] : undefined);
@@ -545,4 +545,3 @@ export const upCommand = new Command("up")
545
545
  await withTiltCheck(action);
546
546
  }
547
547
  });
548
- //# sourceMappingURL=up.js.map
@@ -7,6 +7,7 @@ import { basename, dirname, join, resolve, win32 } from "node:path";
7
7
  import { fileURLToPath } from "node:url";
8
8
  import chalk from "chalk";
9
9
  import { Command } from "commander";
10
+ import { PACKAGE_JSON } from "../utils/constants.js";
10
11
  import { getErrorMessage, logVerbose, showErrorAndExit } from "../utils/errors.js";
11
12
  import { showCancelled } from "../utils/formatting.js";
12
13
  import { getPackageVersion } from "../utils/paths.js";
@@ -377,7 +378,7 @@ async function upgradeViaGit(path) {
377
378
  stdio: "pipe",
378
379
  timeout: 30000,
379
380
  });
380
- if (existsSync(join(path, "cli", "package.json"))) {
381
+ if (existsSync(join(path, "cli", PACKAGE_JSON))) {
381
382
  spinner.text = "Rebuilding CLI...";
382
383
  execFileSync(findOnPath("bun") ?? "bun", ["install"], {
383
384
  cwd: join(path, "cli"),
@@ -634,4 +635,3 @@ export const upgradeCommand = new Command("upgrade")
634
635
  }
635
636
  }
636
637
  });
637
- //# sourceMappingURL=upgrade.js.map
@@ -8,4 +8,3 @@ export const versionCommand = new Command("version")
8
8
  .action(() => {
9
9
  console.log(getPackageVersion());
10
10
  });
11
- //# sourceMappingURL=version.js.map