@inkeep/agents-cli 0.0.0-dev-20251029224908 → 0.0.0-dev-20251030152636

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/index.js +52 -16
  2. package/package.json +5 -4
package/dist/index.js CHANGED
@@ -44193,8 +44193,8 @@ ${lanes.join("\n")}
44193
44193
  function isMissingList(arr) {
44194
44194
  return !!arr.isMissingList;
44195
44195
  }
44196
- function parseBracketedList(kind, parseElement, open, close) {
44197
- if (parseExpected(open)) {
44196
+ function parseBracketedList(kind, parseElement, open2, close) {
44197
+ if (parseExpected(open2)) {
44198
44198
  const result = parseDelimitedList(kind, parseElement);
44199
44199
  parseExpected(close);
44200
44200
  return result;
@@ -46629,7 +46629,7 @@ ${lanes.join("\n")}
46629
46629
  );
46630
46630
  return finishNode(factory2.createJsxSpreadAttribute(expression), pos);
46631
46631
  }
46632
- function parseJsxClosingElement(open, inExpressionContext) {
46632
+ function parseJsxClosingElement(open2, inExpressionContext) {
46633
46633
  const pos = getNodePos();
46634
46634
  parseExpected(
46635
46635
  31
@@ -46643,7 +46643,7 @@ ${lanes.join("\n")}
46643
46643
  /*shouldAdvance*/
46644
46644
  false
46645
46645
  )) {
46646
- if (inExpressionContext || !tagNamesAreEquivalent(open.tagName, tagName)) {
46646
+ if (inExpressionContext || !tagNamesAreEquivalent(open2.tagName, tagName)) {
46647
46647
  nextToken();
46648
46648
  } else {
46649
46649
  scanJsxText();
@@ -195439,18 +195439,18 @@ ${content}
195439
195439
  /* Code */
195440
195440
  );
195441
195441
  }
195442
- function spanForObjectOrArrayLiteral(node, open = 19) {
195442
+ function spanForObjectOrArrayLiteral(node, open2 = 19) {
195443
195443
  return spanForNode(
195444
195444
  node,
195445
195445
  /*autoCollapse*/
195446
195446
  false,
195447
195447
  /*useFullStart*/
195448
195448
  !isArrayLiteralExpression(node.parent) && !isCallExpression(node.parent),
195449
- open
195449
+ open2
195450
195450
  );
195451
195451
  }
195452
- function spanForNode(hintSpanNode, autoCollapse = false, useFullStart = true, open = 19, close = open === 19 ? 20 : 24) {
195453
- const openToken = findChildOfKind(n, open, sourceFile);
195452
+ function spanForNode(hintSpanNode, autoCollapse = false, useFullStart = true, open2 = 19, close = open2 === 19 ? 20 : 24) {
195453
+ const openToken = findChildOfKind(n, open2, sourceFile);
195454
195454
  const closeToken = findChildOfKind(n, close, sourceFile);
195455
195455
  return openToken && closeToken && spanBetweenTokens(openToken, closeToken, hintSpanNode, sourceFile, autoCollapse, useFullStart);
195456
195456
  }
@@ -198241,9 +198241,9 @@ ${options.prefix}` : "\n" : options.prefix
198241
198241
  return end;
198242
198242
  }
198243
198243
  function getClassOrObjectBraceEnds(cls, sourceFile) {
198244
- const open = findChildOfKind(cls, 19, sourceFile);
198244
+ const open2 = findChildOfKind(cls, 19, sourceFile);
198245
198245
  const close = findChildOfKind(cls, 20, sourceFile);
198246
- return [open == null ? void 0 : open.end, close == null ? void 0 : close.end];
198246
+ return [open2 == null ? void 0 : open2.end, close == null ? void 0 : close.end];
198247
198247
  }
198248
198248
  function getMembersOrProperties(node) {
198249
198249
  return isObjectLiteralExpression(node) ? node.properties : node.members;
@@ -238776,10 +238776,31 @@ import { fork } from "child_process";
238776
238776
  import { existsSync as existsSync2 } from "fs";
238777
238777
  import { createRequire } from "module";
238778
238778
  import { dirname, join as join2 } from "path";
238779
+ import * as p2 from "@clack/prompts";
238779
238780
  import chalk3 from "chalk";
238780
238781
  import fs4 from "fs-extra";
238781
- import * as p2 from "@clack/prompts";
238782
+ import open from "open";
238782
238783
  var require2 = createRequire(import.meta.url);
238784
+ async function waitForServer(host, port, maxAttempts = 60) {
238785
+ for (let i = 0; i < maxAttempts; i++) {
238786
+ try {
238787
+ const response = await fetch(`http://${host}:${port}`, {
238788
+ method: "GET",
238789
+ signal: AbortSignal.timeout(2e3)
238790
+ });
238791
+ if (response.ok) {
238792
+ const text4 = await response.text();
238793
+ if (text4 && text4.length > 0 && text4.includes("<!DOCTYPE html>")) {
238794
+ await new Promise((resolve6) => setTimeout(resolve6, 1e3));
238795
+ return true;
238796
+ }
238797
+ }
238798
+ } catch {
238799
+ }
238800
+ await new Promise((resolve6) => setTimeout(resolve6, 500));
238801
+ }
238802
+ return false;
238803
+ }
238783
238804
  function resolveWebRuntime(isRoot = false) {
238784
238805
  try {
238785
238806
  const pkg = require2.resolve("@inkeep/agents-manage-ui/package.json");
@@ -238800,7 +238821,11 @@ Error: ${err instanceof Error ? err.message : "Unknown error"}`
238800
238821
  );
238801
238822
  }
238802
238823
  }
238803
- function startWebApp({ port, host }) {
238824
+ async function startWebApp({
238825
+ port,
238826
+ host,
238827
+ openBrowser
238828
+ }) {
238804
238829
  console.log("");
238805
238830
  const s = p2.spinner();
238806
238831
  s.start("Starting dashboard server...");
@@ -238828,6 +238853,16 @@ function startWebApp({ port, host }) {
238828
238853
  console.log("");
238829
238854
  console.log(chalk3.gray("Press Ctrl+C to stop the server"));
238830
238855
  console.log("");
238856
+ if (openBrowser) {
238857
+ console.log(chalk3.gray("Waiting for server to be ready..."));
238858
+ const isReady = await waitForServer(host, port);
238859
+ if (isReady) {
238860
+ await open(`http://${host}:${port}`);
238861
+ } else {
238862
+ console.log(chalk3.yellow("\u26A0\uFE0F Server did not respond in time, skipping browser open"));
238863
+ console.log(chalk3.gray(` You can manually open: http://${host}:${port}`));
238864
+ }
238865
+ }
238831
238866
  process.on("SIGINT", () => {
238832
238867
  console.log("");
238833
238868
  console.log(chalk3.yellow("\n\u{1F6D1} Stopping dashboard server..."));
@@ -239003,7 +239038,7 @@ This project can be deployed to any platform that supports Next.js:
239003
239038
  }
239004
239039
  }
239005
239040
  async function devCommand(options) {
239006
- const { port, host, build, outputDir, path: path4, export: exportFlag } = options;
239041
+ const { port, host, build, outputDir, path: path4, export: exportFlag, openBrowser } = options;
239007
239042
  if (path4) {
239008
239043
  const rt = resolveWebRuntime(true);
239009
239044
  console.log(rt);
@@ -239017,7 +239052,7 @@ async function devCommand(options) {
239017
239052
  await buildNextApp({ outputDir });
239018
239053
  return;
239019
239054
  }
239020
- await startWebApp({ port, host });
239055
+ await startWebApp({ port, host, openBrowser });
239021
239056
  }
239022
239057
 
239023
239058
  // src/commands/init.ts
@@ -240757,14 +240792,15 @@ program.command("list-agent").description("List all available agents for a speci
240757
240792
  const config = options.config || options.configFilePath;
240758
240793
  await listAgentsCommand({ ...options, config });
240759
240794
  });
240760
- program.command("dev").description("Start the Inkeep dashboard server").option("--port <port>", "Port to run the server on", "3000").option("--host <host>", "Host to bind the server to", "localhost").option("--build", "Build the Dashboard UI for production", false).option("--export", "Export the Next.js project source files", false).option("--output-dir <dir>", "Output directory for build files", "./inkeep-dev").option("--path", "Output the path to the Dashboard UI", false).action(async (options) => {
240795
+ program.command("dev").description("Start the Inkeep dashboard server").option("--port <port>", "Port to run the server on", "3000").option("--host <host>", "Host to bind the server to", "localhost").option("--build", "Build the Dashboard UI for production", false).option("--export", "Export the Next.js project source files", false).option("--output-dir <dir>", "Output directory for build files", "./inkeep-dev").option("--path", "Output the path to the Dashboard UI", false).option("--open-browser", "Open the browser", false).action(async (options) => {
240761
240796
  await devCommand({
240762
240797
  port: parseInt(options.port, 10),
240763
240798
  host: options.host,
240764
240799
  build: options.build,
240765
240800
  outputDir: options.outputDir,
240766
240801
  path: options.path,
240767
- export: options.export
240802
+ export: options.export,
240803
+ openBrowser: options.openBrowser
240768
240804
  });
240769
240805
  });
240770
240806
  program.command("update").description("Update @inkeep/agents-cli to the latest version").option("--check", "Check for updates without installing").option("--force", "Force update even if already on latest version").action(async (options) => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@inkeep/agents-cli",
3
- "version": "0.0.0-dev-20251029224908",
3
+ "version": "0.0.0-dev-20251030152636",
4
4
  "description": "Inkeep CLI tool",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -48,8 +48,9 @@
48
48
  "recast": "^0.23.0",
49
49
  "ts-morph": "^26.0.0",
50
50
  "tsx": "^4.20.5",
51
- "@inkeep/agents-core": "^0.0.0-dev-20251029224908",
52
- "@inkeep/agents-sdk": "^0.0.0-dev-20251029224908"
51
+ "open": "^10.2.0",
52
+ "@inkeep/agents-core": "^0.0.0-dev-20251030152636",
53
+ "@inkeep/agents-sdk": "^0.0.0-dev-20251030152636"
53
54
  },
54
55
  "devDependencies": {
55
56
  "@types/degit": "^2.8.6",
@@ -62,7 +63,7 @@
62
63
  "vitest": "^3.2.4"
63
64
  },
64
65
  "peerDependencies": {
65
- "@inkeep/agents-manage-ui": "0.0.0-dev-20251029224908",
66
+ "@inkeep/agents-manage-ui": "0.0.0-dev-20251030152636",
66
67
  "zod": "^4.1.11"
67
68
  },
68
69
  "engines": {