vybekiit 0.7.15 → 0.7.17

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 (2) hide show
  1. package/dist/bin.js +58 -20
  2. package/package.json +8 -8
package/dist/bin.js CHANGED
@@ -11140,9 +11140,10 @@ var defaultStartDetached = (cwd, bin, args) => {
11140
11140
  return false;
11141
11141
  }
11142
11142
  };
11143
+ var claudeTerminalCommand = (appPath, prompt) => `cd ${JSON.stringify(appPath)} && claude ${JSON.stringify(prompt)}; exec "\${SHELL:-/bin/zsh}" -l`;
11143
11144
  var openClaudeWithSeed = async (appPath, prompt, platform = process7.platform) => {
11144
11145
  if (platform === "darwin") {
11145
- const shellCommand = `cd ${JSON.stringify(appPath)} && claude ${JSON.stringify(prompt)}`;
11146
+ const shellCommand = claudeTerminalCommand(appPath, prompt);
11146
11147
  const osa = makeExec("osascript");
11147
11148
  const result = await osa([
11148
11149
  "-e",
@@ -11190,7 +11191,7 @@ var defaultPnpmCommand = async () => {
11190
11191
  return null;
11191
11192
  };
11192
11193
  var wait = async (milliseconds) => await new Promise((resolve19) => setTimeout(resolve19, milliseconds));
11193
- var defaultWaitForPreview = async (url) => {
11194
+ var waitForPreview = async (url) => {
11194
11195
  const attemptPreview = async (remainingAttempts) => {
11195
11196
  try {
11196
11197
  const response = await fetch(url, { redirect: "follow" });
@@ -11242,7 +11243,7 @@ var defaultDeps = () => ({
11242
11243
  runCommand: defaultRunCommand,
11243
11244
  startDetached: defaultStartDetached,
11244
11245
  openClaude: (appPath, prompt) => openClaudeWithSeed(appPath, prompt, process7.platform),
11245
- waitForPreview: defaultWaitForPreview,
11246
+ waitForPreview,
11246
11247
  openBrowser: defaultOpenBrowser,
11247
11248
  prepareProjectTools: async (appPath) => {
11248
11249
  try {
@@ -11260,8 +11261,8 @@ var defaultDeps = () => ({
11260
11261
  platform: process7.platform
11261
11262
  });
11262
11263
  var projectToolsLines = (ready) => ready ? [
11263
- " \u2022 @vybekiit/ui + the UI catalog are available to Claude",
11264
- " \u2022 Global VybeKiit tools, browser automation, and matching project skills are connected"
11264
+ " \u2022 @vybekiit/ui + the UI catalog are available to your coding agent",
11265
+ " \u2022 VybeKiit tools, browser automation, and matching project skills are connected"
11265
11266
  ] : [];
11266
11267
  var formatSessionOneLines = (result) => {
11267
11268
  if (result.appPath === null) {
@@ -11306,13 +11307,13 @@ var formatSessionOneLines = (result) => {
11306
11307
  if (result.claudeOpened) {
11307
11308
  lines.push(' \u2022 Claude Code opening with: "Set up my app."');
11308
11309
  } else {
11309
- lines.push(' \u2022 Open Claude Code in that folder and say: "Set up my app."');
11310
- lines.push(` cd ${result.appPath} && claude "Set up my app."`);
11310
+ lines.push(' \u2022 Open that folder in your coding agent and say: "Set up my app."');
11311
+ lines.push(` ${result.appPath}`);
11311
11312
  }
11312
11313
  lines.push(
11313
11314
  "",
11314
11315
  "Report mode is built in \u2014 if something looks wrong, press Option+Shift+R",
11315
- "(Alt+Shift+R on Windows), click it, and tell Claude what is off.",
11316
+ "(Alt+Shift+R on Windows), click it, and tell your coding agent what is off.",
11316
11317
  ""
11317
11318
  );
11318
11319
  return lines;
@@ -11429,6 +11430,7 @@ Creating your first web app at ${appPath}\u2026
11429
11430
  // src/commands/createUiLibrary.ts
11430
11431
  var DEFAULT_UI_LIBRARY_DIR_NAME = "vybekiit-ui-library";
11431
11432
  var UI_LIBRARY_GALLERY_URL = "https://ui.vybekiit.com";
11433
+ var UI_LIBRARY_LOCAL_URL = "http://127.0.0.1:3000/en";
11432
11434
  var UI_LIBRARY_SEED_PROMPT = `I opened my VybeKiit UI library workspace.
11433
11435
 
11434
11436
  Work ONLY in this folder (the kit workspace). Do not claim the UI library is missing.
@@ -11552,6 +11554,7 @@ var defaultDeps2 = () => ({
11552
11554
  isEmptyDir: defaultIsEmptyDir2,
11553
11555
  runCommand: defaultRunCommand2,
11554
11556
  startDetached: defaultStartDetached2,
11557
+ waitForPreview,
11555
11558
  openClaude: (appPath, prompt) => openClaudeWithSeed(appPath, prompt, process8.platform),
11556
11559
  openUrl: defaultOpenUrl,
11557
11560
  pnpmCommand: defaultPnpmCommand2,
@@ -11589,7 +11592,11 @@ var formatCreateUiLibraryLines = (result) => {
11589
11592
  lines.push(" \u2022 Build packages: pnpm build:packages");
11590
11593
  }
11591
11594
  if (result.devStarted) {
11592
- lines.push(" \u2022 Local app preview starting (http://localhost:3000)");
11595
+ if (result.localPreviewOpened) {
11596
+ lines.push(` \u2022 Local app opened: ${UI_LIBRARY_LOCAL_URL}`);
11597
+ } else {
11598
+ lines.push(` \u2022 Open your local app: ${UI_LIBRARY_LOCAL_URL}`);
11599
+ }
11593
11600
  }
11594
11601
  if (result.galleryOpened) {
11595
11602
  lines.push(` \u2022 UI gallery opened: ${UI_LIBRARY_GALLERY_URL}`);
@@ -11627,6 +11634,8 @@ var runCreateUiLibrary = async (args = [], deps = defaultDeps2()) => {
11627
11634
  depsInstalled: false,
11628
11635
  packagesBuilt: false,
11629
11636
  devStarted: false,
11637
+ previewReady: false,
11638
+ localPreviewOpened: false,
11630
11639
  galleryOpened: false,
11631
11640
  claudeOpened: false
11632
11641
  };
@@ -11654,6 +11663,8 @@ Creating UI library kit workspace at ${appPath}\u2026
11654
11663
  depsInstalled: false,
11655
11664
  packagesBuilt: false,
11656
11665
  devStarted: false,
11666
+ previewReady: false,
11667
+ localPreviewOpened: false,
11657
11668
  galleryOpened: false,
11658
11669
  claudeOpened: false
11659
11670
  };
@@ -11679,6 +11690,8 @@ Creating UI library kit workspace at ${appPath}\u2026
11679
11690
  devStarted = deps.startDetached(appPath, pnpmBin, [...pnpmPrefix, "dev"]);
11680
11691
  }
11681
11692
  }
11693
+ const previewReady = devStarted ? await deps.waitForPreview(UI_LIBRARY_LOCAL_URL) : false;
11694
+ const localPreviewOpened = previewReady ? await deps.openUrl(UI_LIBRARY_LOCAL_URL) : false;
11682
11695
  let galleryOpened = false;
11683
11696
  if (inputs.openGallery) {
11684
11697
  process8.stdout.write(`
@@ -11697,6 +11710,8 @@ Opening UI gallery: ${UI_LIBRARY_GALLERY_URL}
11697
11710
  depsInstalled,
11698
11711
  packagesBuilt,
11699
11712
  devStarted,
11713
+ previewReady,
11714
+ localPreviewOpened,
11700
11715
  galleryOpened,
11701
11716
  claudeOpened
11702
11717
  };
@@ -26488,22 +26503,42 @@ var tools = [
26488
26503
  }
26489
26504
  ];
26490
26505
  var automationProjectRoot2 = () => process.env.VYBEKIIT_PROJECT_ROOT || process.cwd();
26491
- var uiCatalogIndexPath = () => {
26506
+ var uiCatalogIndexPaths = () => {
26492
26507
  const configuredCatalogPath = process.env.VYBEKIIT_UI_CATALOG_PATH;
26493
26508
  if (configuredCatalogPath) {
26494
- return configuredCatalogPath;
26509
+ return [configuredCatalogPath];
26495
26510
  }
26496
- return join35(automationProjectRoot2(), ".vybekiit/agent/ui-catalog-index.json");
26511
+ const projectRoot = automationProjectRoot2();
26512
+ return [
26513
+ join35(projectRoot, ".vybekiit/agent/ui-catalog-index.json"),
26514
+ join35(projectRoot, "templates/web/.vybekiit/agent/ui-catalog-index.json")
26515
+ ];
26497
26516
  };
26498
26517
  var cachedCatalog;
26499
26518
  var loadUiCatalog = async () => {
26500
- const catalogPath = uiCatalogIndexPath();
26501
- if (cachedCatalog !== void 0 && cachedCatalog.path === catalogPath) {
26519
+ const catalogPaths = uiCatalogIndexPaths();
26520
+ const cached = catalogPaths.find((candidatePath) => cachedCatalog?.path === candidatePath);
26521
+ if (cached !== void 0 && cachedCatalog !== void 0) {
26502
26522
  return cachedCatalog.catalog;
26503
26523
  }
26524
+ const catalogReads = await Promise.allSettled(
26525
+ catalogPaths.map((candidatePath) => readFile18(candidatePath, "utf8"))
26526
+ );
26527
+ const availableIndex = catalogReads.findIndex(
26528
+ (candidateRead) => candidateRead.status === "fulfilled"
26529
+ );
26530
+ if (availableIndex === -1) {
26531
+ const [firstFailure] = catalogReads;
26532
+ const reason = firstFailure?.status === "rejected" ? firstFailure.reason : "Catalog not found";
26533
+ return { error: reason instanceof Error ? reason.message : String(reason) };
26534
+ }
26535
+ const catalogRead = catalogReads[availableIndex];
26536
+ const catalogPath = catalogPaths[availableIndex];
26537
+ if (catalogRead?.status !== "fulfilled" || catalogPath === void 0) {
26538
+ return { error: "Catalog not found" };
26539
+ }
26504
26540
  try {
26505
- const json = await readFile18(catalogPath, "utf8");
26506
- const catalog = loadCatalog(json);
26541
+ const catalog = loadCatalog(catalogRead.value);
26507
26542
  cachedCatalog = { path: catalogPath, catalog };
26508
26543
  return catalog;
26509
26544
  } catch (error) {
@@ -31442,11 +31477,12 @@ var installGlobalSkills = async (paths, sourceDir = paths.bundledSkillsDir) => {
31442
31477
 
31443
31478
  // src/global/runGlobalInstall.ts
31444
31479
  var shouldRunSessionOneOnInstall = (args, isFirstInstall) => isFirstInstall || args.includes("--session-one");
31480
+ var globalSetupComplete = (managedFilesReady, mcpInstallation) => managedFilesReady && (mcpInstallation.claudeMissing || isVybekiitMcpReady(mcpInstallation));
31445
31481
  var formatGlobalInstallSummary = (summary) => {
31446
31482
  const isUpdate = summary.previousVersion !== null && summary.previousVersion !== summary.version;
31447
31483
  const isRerun = summary.previousVersion !== null && summary.previousVersion === summary.version;
31448
31484
  const skillsEmpty = summary.skillsInstalled === 0 && summary.skillSample.length === 0;
31449
- let headline = `\u2705 VybeKiit ${summary.version} is now set up globally in Claude Code.`;
31485
+ let headline = summary.claudeMissing ? `\u2705 VybeKiit ${summary.version} is ready for your coding agent.` : `\u2705 VybeKiit ${summary.version} is now set up globally in Claude Code.`;
31450
31486
  if (skillsEmpty) {
31451
31487
  headline = `\u2717 VybeKiit ${summary.version} global setup did not land any managed skills.`;
31452
31488
  } else if (isUpdate) {
@@ -31475,7 +31511,9 @@ var formatGlobalInstallSummary = (summary) => {
31475
31511
  );
31476
31512
  }
31477
31513
  if (summary.claudeMissing) {
31478
- lines.push(" \u2022 MCP skipped \u2014 the `claude` command was not found on your PATH");
31514
+ lines.push(
31515
+ " \u2022 MCP Claude Code is optional and was not found. Continuing with your coding agent."
31516
+ );
31479
31517
  } else {
31480
31518
  const enabledLabel = summary.mcpEnabled.length > 0 ? summary.mcpEnabled.join(", ") : "none newly added";
31481
31519
  lines.push(` \u2022 MCP ${enabledLabel} (VybeKiit tools + browser automation + live docs)`);
@@ -31568,9 +31606,9 @@ var runGlobalInstall = async (args, gate = checkEntitlement) => {
31568
31606
  process29.stdout.write(`${line}
31569
31607
  `);
31570
31608
  }
31571
- if (!(isGloballyInstalled(postStatus) && isVybekiitMcpReady(mcp))) {
31609
+ if (!globalSetupComplete(isGloballyInstalled(postStatus), mcp)) {
31572
31610
  process29.stderr.write(
31573
- "VybeKiit global install incomplete: expected managed skills, global MCP, /vybekiit, and CLAUDE.md awareness.\n"
31611
+ "VybeKiit setup is incomplete: the managed files or an available Claude Code connection could not be prepared.\n"
31574
31612
  );
31575
31613
  return 1;
31576
31614
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "vybekiit",
3
- "version": "0.7.15",
3
+ "version": "0.7.17",
4
4
  "description": "Choose your services, sign in, create a VybeKiit app, and open its verified local welcome page.",
5
5
  "license": "MIT",
6
6
  "publishConfig": {
@@ -32,13 +32,13 @@
32
32
  "tsup": "8.5.1",
33
33
  "typescript": "5.7.2",
34
34
  "vitest": "3.2.6",
35
- "@vybekiit/db": "0.7.15",
36
- "@vybekiit/deploy": "0.7.15",
37
- "@vybekiit/core": "0.7.15",
38
- "@vybekiit/report-mode": "0.7.15",
39
- "@vybekiit/payments": "0.7.15",
40
- "@vybekiit/agent-mcp": "0.7.15",
41
- "@vybekiit/agent-kit": "0.7.15"
35
+ "@vybekiit/agent-kit": "0.7.17",
36
+ "@vybekiit/agent-mcp": "0.7.17",
37
+ "@vybekiit/core": "0.7.17",
38
+ "@vybekiit/deploy": "0.7.17",
39
+ "@vybekiit/payments": "0.7.17",
40
+ "@vybekiit/report-mode": "0.7.17",
41
+ "@vybekiit/db": "0.7.17"
42
42
  },
43
43
  "scripts": {
44
44
  "build": "tsup && node scripts/bundleGlobalSkills.mjs",