adhdev 0.9.76-rc.5 → 0.9.76-rc.7

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/cli/index.js CHANGED
@@ -40056,7 +40056,7 @@ function resolveAdhdevMcpServerLaunch(options) {
40056
40056
  if (!entryPath) return null;
40057
40057
  return {
40058
40058
  command: options.nodeExecutable?.trim() || process.execPath,
40059
- args: [entryPath, "--repo-mesh", options.meshId]
40059
+ args: [entryPath, "--mode", "ipc", "--repo-mesh", options.meshId]
40060
40060
  };
40061
40061
  }
40062
40062
  function resolveAdhdevMcpEntryPath(explicitPath) {
@@ -41714,7 +41714,8 @@ var init_router = __esm({
41714
41714
  };
41715
41715
  if (args?.inlineMesh) {
41716
41716
  mcpServerEntry.env = {
41717
- ADHDEV_INLINE_MESH: JSON.stringify(mesh)
41717
+ ADHDEV_INLINE_MESH: JSON.stringify(mesh),
41718
+ ADHDEV_MCP_TRANSPORT: "ipc"
41718
41719
  };
41719
41720
  }
41720
41721
  const mcpConfig = {
@@ -80988,13 +80989,14 @@ var init_server_connection = __esm({
80988
80989
  reject(new Error(`Mesh command timed out after ${timeoutMs}ms`));
80989
80990
  }, timeoutMs);
80990
80991
  const handler = (msg) => {
80991
- if (msg.payload?.requestId !== requestId) return;
80992
+ const body = msg.payload && typeof msg.payload === "object" ? { ...msg, ...msg.payload } : msg;
80993
+ if (body.requestId !== requestId) return;
80992
80994
  this.off("daemon_mesh_result", handler);
80993
80995
  clearTimeout(timer);
80994
- if (msg.payload?.success === false) {
80995
- reject(new Error(msg.payload?.error ?? "Mesh command failed"));
80996
+ if (body.success === false) {
80997
+ reject(new Error(body.error ?? "Mesh command failed"));
80996
80998
  } else {
80997
- resolve23(msg.payload?.result);
80999
+ resolve23(body.result);
80998
81000
  }
80999
81001
  };
81000
81002
  this.on("daemon_mesh_result", handler);
@@ -90012,7 +90014,9 @@ var init_daemon_mesh_manager = __esm({
90012
90014
  "read_chat",
90013
90015
  "git_status",
90014
90016
  "git_diff_summary",
90015
- "launch_cli"
90017
+ "launch_cli",
90018
+ "git_checkpoint",
90019
+ "resolve_action"
90016
90020
  ]);
90017
90021
  setRules(rules) {
90018
90022
  const valid = [];
@@ -90303,7 +90307,7 @@ var init_adhdev_daemon = __esm({
90303
90307
  init_version();
90304
90308
  init_src();
90305
90309
  init_runtime_defaults();
90306
- pkgVersion = resolvePackageVersion({ injectedVersion: "0.9.76-rc.5" });
90310
+ pkgVersion = resolvePackageVersion({ injectedVersion: "0.9.76-rc.7" });
90307
90311
  AdhdevDaemon = class _AdhdevDaemon {
90308
90312
  localHttpServer = null;
90309
90313
  localWss = null;
@@ -91405,7 +91409,20 @@ ${err?.stack || ""}`);
91405
91409
  return;
91406
91410
  }
91407
91411
  try {
91408
- const result = await this.components.router.execute(command, normalizedArgs, "ipc");
91412
+ let result;
91413
+ if (command === "mesh_relay_command") {
91414
+ if (!this.meshManager) throw new Error("Mesh manager is not initialized");
91415
+ const targetDaemonId = typeof normalizedArgs.targetDaemonId === "string" ? normalizedArgs.targetDaemonId : "";
91416
+ const relayedCommand = typeof normalizedArgs.command === "string" ? normalizedArgs.command : "";
91417
+ const relayedArgs = normalizedArgs.args && typeof normalizedArgs.args === "object" ? normalizedArgs.args : {};
91418
+ if (!targetDaemonId || !relayedCommand) {
91419
+ throw new Error("mesh_relay_command requires targetDaemonId and command");
91420
+ }
91421
+ const relayResult = await this.meshManager.sendCommand(targetDaemonId, relayedCommand, relayedArgs);
91422
+ result = { success: true, result: relayResult };
91423
+ } else {
91424
+ result = await this.components.router.execute(command, normalizedArgs, "ipc");
91425
+ }
91409
91426
  ws.send(JSON.stringify({
91410
91427
  type: "ext:command_result",
91411
91428
  payload: {