@conveno/cli 0.2.0-rc.17 → 0.2.0-rc.18

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,5 +1,5 @@
1
1
  import { appendFileSync } from "node:fs";
2
- import { S as appendHookLog, ot as hookLogLine } from "./dist-Dc50_P_f.js";
2
+ import { ut as hookLogLine, w as appendHookLog } from "./dist-CSSvrcKr.js";
3
3
  import { n as connectOpts } from "./ctx-tYftvhz_.js";
4
4
  // src/hook.ts
5
5
  /**
@@ -1,13 +1,13 @@
1
1
  import { homedir } from "node:os";
2
- import { n as antigravityAdapter } from "./dist-CTw3arJP.js";
2
+ import { n as connect } from "./dist-DAVtixeC.js";
3
+ import { $ as endTurnContinuation, Bt as pendingTurn, G as dataDir, K as dataPaths, Mn as waitForWorkBatch, Nt as ownSession, Pt as parseCliVersion, Xt as readAncestry, cn as requeueMessages, dt as hookLogPath, ft as hostAlive, i as CLI_DESCRIPTORS, jn as waitForWork, n as CLAUDE_PENDING_TURN_FOLDER, tn as readSettings, xn as startTurnContext, zt as pendingHookContext } from "./dist-CSSvrcKr.js";
4
+ import { n as antigravityAdapter } from "./dist-D6Xoip5W.js";
3
5
  import { isAbsolute, join } from "node:path";
4
- import { At as parseCliVersion, Dn as waitForWork, Ft as pendingHookContext, H as dataPaths, It as pendingTurn, Kt as readAncestry, On as waitForWorkBatch, V as dataDir, Y as endTurnContinuation, Zt as readSettings, _n as startTurnContext, ct as hostAlive, in as requeueMessages, kt as ownSession, n as CLAUDE_PENDING_TURN_FOLDER, st as hookLogPath } from "./dist-Dc50_P_f.js";
5
6
  import { readFile } from "node:fs/promises";
6
7
  import { applyEdits, modify, parse, printParseErrorCode } from "jsonc-parser";
7
- import { t as codexAdapter } from "./dist-CvKAege3.js";
8
- import { t as grokAdapter } from "./dist-Bb2opAjB.js";
9
- import { n as connect } from "./dist-BgAfkqeX.js";
10
- import { t as runHook } from "./hook-BLSrNkFF.js";
8
+ import { t as codexAdapter } from "./dist-DTMnNySx.js";
9
+ import { t as grokAdapter } from "./dist-CFsDqevs.js";
10
+ import { t as runHook } from "./hook-BA-tI6Oc.js";
11
11
  // ../adapters/claude/dist/index.js
12
12
  const isObject = (v) => typeof v === "object" && v !== null && !Array.isArray(v);
13
13
  /** Read a JSON object file. Missing or blank files give `{}`; anything else that is not a JSON object throws. */
@@ -1271,17 +1271,26 @@ function delivery(detection) {
1271
1271
  idleWake: supported
1272
1272
  };
1273
1273
  }
1274
- const opencodeAdapter = {
1275
- cli: "opencode",
1276
- displayName: "OpenCode",
1277
- deliveryTier: "inbox",
1278
- detect,
1279
- plan,
1280
- uninstallPlan,
1281
- hook,
1282
- listenEvents: ["Listen"],
1283
- delivery
1274
+ // src/adapters.ts
1275
+ const ADAPTERS = {
1276
+ claude: claudeAdapter,
1277
+ codex: codexAdapter,
1278
+ opencode: {
1279
+ cli: "opencode",
1280
+ displayName: "OpenCode",
1281
+ deliveryTier: "inbox",
1282
+ detect,
1283
+ plan,
1284
+ uninstallPlan,
1285
+ hook,
1286
+ listenEvents: ["Listen"],
1287
+ delivery
1288
+ },
1289
+ antigravity: antigravityAdapter,
1290
+ grok: grokAdapter
1284
1291
  };
1292
+ /** The adapters in the order the descriptors list the CLIs. */
1293
+ const adapterList = () => CLI_DESCRIPTORS.map((d) => ADAPTERS[d.id]);
1285
1294
  // src/hook-entry.ts
1286
1295
  function readAllStdin() {
1287
1296
  if (process.stdin.isTTY) return Promise.resolve("");
@@ -1310,13 +1319,7 @@ function createHookCtx() {
1310
1319
  return {
1311
1320
  dataDir: data,
1312
1321
  ...process.env.CONVENO_HOOK_LOG === "0" ? {} : { hookLog: hookLogPath(data) },
1313
- adapters: [
1314
- claudeAdapter,
1315
- codexAdapter,
1316
- opencodeAdapter,
1317
- antigravityAdapter,
1318
- grokAdapter
1319
- ],
1322
+ adapters: adapterList(),
1320
1323
  out: (s) => void process.stdout.write(s),
1321
1324
  err: (s) => void process.stderr.write(s),
1322
1325
  readStdin: readAllStdin,
@@ -1340,4 +1343,4 @@ function createHookCtx() {
1340
1343
  function runHookEntry(argv) {
1341
1344
  return runHook(createHookCtx(), argv);
1342
1345
  }
1343
- export { opencodeAdapter as a, runHookEntry as i, isProcessAlive as n, claudeAdapter as o, readAllStdin as r, createHookCtx as t };
1346
+ export { adapterList as a, runHookEntry as i, isProcessAlive as n, readAllStdin as r, createHookCtx as t };
@@ -0,0 +1 @@
1
+ export { i as runHookEntry } from "./hook-entry-BwzBtAnd.js";
@@ -1,13 +1,13 @@
1
- import { $t as realSpawnDeps, Fn as CLI_KINDS, H as dataPaths, M as cleanModelName, Nt as parseWorkerAccess, d as SPAWN_TABLE, f as SpawnError, gn as spawnSession, ln as runLaunchFile, p as WORKER_ACCESS, u as SPAWN_CLIS } from "./dist-Dc50_P_f.js";
2
- import { A as runRelay, I as runAccount, L as runLogin, M as runDaemon, P as VERSION, R as runLogout, b as workerAccessLine, i as runDoctor, k as runDevices, m as runSetup, p as runInit, t as runUninstall } from "./uninstall-B-deU_wY.js";
1
+ import { K as dataPaths, Lt as parseWorkerAccess, P as cleanModelName, bn as spawnSession, f as SPAWN_CLIS, h as WORKER_ACCESS, m as SpawnError, p as SPAWN_TABLE, pn as runLaunchFile, rn as realSpawnDeps, zn as CLI_KINDS } from "./dist-CSSvrcKr.js";
2
+ import { A as runRelay, I as runAccount, L as runLogin, M as runDaemon, P as VERSION, R as runLogout, b as workerAccessLine, i as runDoctor, k as runDevices, m as runSetup, p as runInit, t as runUninstall } from "./uninstall-01_NStQ4.js";
3
3
  import { a as parseFlags, i as commandHelp, n as COMMANDS, r as COMMAND_NAMES, t as ALL_COMMAND_NAMES } from "./args-CtyKPZuN.js";
4
- import { t as daemonProblem } from "./daemonError-BwdtKOCy.js";
4
+ import { t as daemonProblem } from "./daemonError-CDgEtvy7.js";
5
5
  import { chmod, mkdir, writeFile } from "node:fs/promises";
6
6
  import { join, resolve } from "node:path";
7
7
  import { a as fail, c as plural, d as warnBlock, n as cmd, r as columns, s as plainError, t as closest, u as tilde } from "./fmt-C2SsP5Y0.js";
8
- import { t as runHook } from "./hook-BLSrNkFF.js";
8
+ import { t as runHook } from "./hook-BA-tI6Oc.js";
9
9
  import { n as connectOpts, t as adapterEnv } from "./ctx-tYftvhz_.js";
10
- import { t as findSession } from "./pick-iuG24FX9.js";
10
+ import { t as findSession } from "./pick-BsMvXuDo.js";
11
11
  import { readFileSync } from "node:fs";
12
12
  // src/errorLog.ts
13
13
  /** The message of an unexpected error, as it is. Not the softened text `plainError` gives. */
@@ -609,11 +609,11 @@ async function dispatch(name, rest, ctx) {
609
609
  case "rename": return runRename(ctx, rest);
610
610
  case "lead": return runLead(ctx, rest);
611
611
  case "spawn": return runSpawn(ctx, rest);
612
- case "acp-host": return (await import("./acp-C-o3rtAB.js")).runAcpHostCmd(ctx, rest);
613
- case "stop": return (await import("./acp-C-o3rtAB.js")).runStop(ctx, rest);
612
+ case "acp-host": return (await import("./acp-CFIh624o.js")).runAcpHostCmd(ctx, rest);
613
+ case "stop": return (await import("./acp-CFIh624o.js")).runStop(ctx, rest);
614
614
  case "spawn-run": return runSpawnRun(ctx, rest);
615
- case "agy-relay": return (await import("./agy-relay-D17zTd_Z.js")).runAgyRelay(ctx, rest);
616
- case "watch": return (await import("./watch-CPZ2X-yt.js")).runWatch(ctx, rest);
615
+ case "agy-relay": return (await import("./agy-relay-BZ3d_-FS.js")).runAgyRelay(ctx, rest);
616
+ case "watch": return (await import("./watch-BIepRTXJ.js")).runWatch(ctx, rest);
617
617
  case "devices": return runDevices(ctx, rest);
618
618
  case "relay": return runRelay(ctx, rest);
619
619
  case "doctor": return runDoctor(ctx, rest);
@@ -652,7 +652,7 @@ function opensApp(env, tty = {
652
652
  async function main(argv, ctx) {
653
653
  const [command, ...rest] = argv;
654
654
  if (command === void 0 && opensApp(ctx.env)) try {
655
- return await (await import("./run-B01nDeos.js")).runTui(ctx);
655
+ return await (await import("./run-BtYGSOMi.js")).runTui(ctx);
656
656
  } catch (e) {
657
657
  ctx.err(`The app could not start (${rawMessage(e)}). Showing the help instead.\n`);
658
658
  ctx.out(helpText(ctx));
@@ -1,4 +1,4 @@
1
- import { Zn as SessionId } from "./dist-Dc50_P_f.js";
1
+ import { tr as SessionId } from "./dist-CSSvrcKr.js";
2
2
  // src/pick.ts
3
3
  /** The online session a name or id means, or undefined when nothing matches. */
4
4
  async function findSession(client, text) {
@@ -1,10 +1,10 @@
1
1
  import { Box, Text, render, useApp, useInput, useStdin, useStdout } from "ink";
2
2
  import { n as connectOpts, t as adapterEnv } from "./ctx-tYftvhz_.js";
3
- import { C as saveChoice, D as warmAcpAdapters, E as unifiedDiff, F as openInBrowser, N as stopDaemonIfRunning, O as PAIR_TIMEOUT_MS, S as connectedTools, T as applyChanges, _ as readWorkerAccess, a as applyOptions, c as collectPlans, d as refreshManifest, f as renewedApprovals, g as UNANSWERED_TEXT, h as ACCESS_TEXT, j as replaceStaleDaemon, l as detectAll, n as inspect, o as approvalWrites, r as partState, s as approvedBySetup, t as runUninstall, u as pendingOptions, v as saveWorkerAccess, w as StaleError, x as chosenTools, y as waitText, z as showCode$1 } from "./uninstall-B-deU_wY.js";
4
- import { t as daemonProblem } from "./daemonError-BwdtKOCy.js";
3
+ import { C as saveChoice, D as warmAcpAdapters, E as unifiedDiff, F as openInBrowser, N as stopDaemonIfRunning, O as PAIR_TIMEOUT_MS, S as connectedTools, T as applyChanges, _ as readWorkerAccess, a as applyOptions, c as collectPlans, d as refreshManifest, f as renewedApprovals, g as UNANSWERED_TEXT, h as ACCESS_TEXT, j as replaceStaleDaemon, l as detectAll, n as inspect, o as approvalWrites, r as partState, s as approvedBySetup, t as runUninstall, u as pendingOptions, v as saveWorkerAccess, w as StaleError, x as chosenTools, y as waitText, z as showCode$1 } from "./uninstall-01_NStQ4.js";
4
+ import { t as daemonProblem } from "./daemonError-CDgEtvy7.js";
5
5
  import { a as fail, n as cmd, s as plainError, u as tilde } from "./fmt-C2SsP5Y0.js";
6
6
  import { createContext, useCallback, useContext, useEffect, useImperativeHandle, useMemo, useReducer, useRef, useState, useSyncExternalStore } from "react";
7
- import { $t as realSpawnDeps, Gt as readAccountTokens, H as dataPaths, Ht as pollDeviceCode, I as compatStatus, L as completeLogin, Mn as writeModelMenu, Pn as writeSettings, Q as fetchAccountStatus, St as logoutAccount, Tt as modelLabel, Vt as planSpawn, W as defaultProcessIo, Xn as SESSION_NAME_PATTERN, Xt as readProcessList, Yt as readModelMenus, Zt as readSettings, d as SPAWN_TABLE, et as findOnPath, fr as sanitizeLine, gn as spawnSession, h as WORKER_UNANSWERED, m as WORKER_ASK_TIMEOUT_CHOICES, nn as requestDeviceCode, p as WORKER_ACCESS, pn as signedInAccountApi, t as AccountError, xt as loginAccountApi } from "./dist-Dc50_P_f.js";
7
+ import { $t as readModelMenus, B as compatStatus, Et as logoutAccount, Gt as planSpawn, In as writeModelMenu, J as defaultProcessIo, K as dataPaths, Kt as pollDeviceCode, Rn as writeSettings, Tt as loginAccountApi, V as completeLogin, Yt as readAccountTokens, _ as WORKER_UNANSWERED, _n as signedInAccountApi, bn as spawnSession, en as readProcessList, er as SESSION_NAME_PATTERN, g as WORKER_ASK_TIMEOUT_CHOICES, gr as sanitizeLine, h as WORKER_ACCESS, i as CLI_DESCRIPTORS, it as findOnPath, kt as modelLabel, nt as fetchAccountStatus, on as requestDeviceCode, p as SPAWN_TABLE, r as CLIS, rn as realSpawnDeps, t as AccountError, tn as readSettings } from "./dist-CSSvrcKr.js";
8
8
  import { i as tokens, n as detectColorLevel, r as detectUnicode } from "./dist-BOwFdixw.js";
9
9
  import stringWidth from "string-width";
10
10
  import { Fragment, jsx, jsxs } from "react/jsx-runtime";
@@ -13,7 +13,7 @@ import { Readable } from "node:stream";
13
13
  import { basename, posix, win32 } from "node:path";
14
14
  import { spawn } from "node:child_process";
15
15
  import { homedir } from "node:os";
16
- import { n as probeModelMenu } from "./dist-hyKfBSdF.js";
16
+ import { n as probeModelMenu } from "./dist-B7liMhCw.js";
17
17
  // src/tui/home/deps.ts
18
18
  /**
19
19
  * What home does outside the store: sign in and out, and take Conveno away. Real in the app, fake
@@ -2293,13 +2293,8 @@ function Toast({ text, tone, width, onDone }) {
2293
2293
  });
2294
2294
  }
2295
2295
  // src/tui/names.ts
2296
- const TOOL_NAMES = {
2297
- claude: "Claude Code",
2298
- codex: "Codex",
2299
- opencode: "OpenCode",
2300
- antigravity: "Antigravity",
2301
- grok: "Grok Build"
2302
- };
2296
+ /** How the app names tools and sessions on screen. No Ink or React in here: the store uses it. */
2297
+ const TOOL_NAMES = Object.fromEntries(CLI_DESCRIPTORS.map((d) => [d.id, d.name]));
2303
2298
  /** "Claude Code" for `claude`. An unknown id shows as it is. */
2304
2299
  const toolName$1 = (cli) => TOOL_NAMES[cli] ?? cli;
2305
2300
  /** The tool a session runs in: "Antigravity app" for the desktop app, else `toolName`. */
@@ -5411,28 +5406,11 @@ function npmGlobal(platform, pkg) {
5411
5406
  }
5412
5407
  /** How to install `cli` on `platform`, or why Conveno cannot do it. Pure. */
5413
5408
  function installPlan(cli, platform) {
5414
- switch (cli) {
5415
- case "claude": return {
5416
- installable: true,
5417
- steps: [script(platform, "https://claude.ai/install.sh", "https://claude.ai/install.ps1")]
5418
- };
5419
- case "codex": return {
5420
- installable: true,
5421
- steps: [npmGlobal(platform, "@openai/codex")]
5422
- };
5423
- case "opencode": return {
5424
- installable: true,
5425
- steps: [npmGlobal(platform, "@opencode/cli")]
5426
- };
5427
- case "grok": return {
5428
- installable: true,
5429
- steps: [script(platform, "https://x.ai/cli/install.sh", "https://x.ai/cli/install.ps1")]
5430
- };
5431
- case "antigravity": return {
5432
- installable: true,
5433
- steps: [script(platform, "https://antigravity.google/cli/install.sh", "https://antigravity.google/cli/install.ps1")]
5434
- };
5435
- }
5409
+ const route = CLIS[cli].install.route;
5410
+ return {
5411
+ installable: true,
5412
+ steps: [route.kind === "script" ? script(platform, route.sh, route.ps) : npmGlobal(platform, route.package)]
5413
+ };
5436
5414
  }
5437
5415
  /**
5438
5416
  * Update route. No tool needs one now: any OpenCode 1.x or 2.x works, so nothing is offered. Kept
@@ -5605,13 +5583,6 @@ async function runInstall(cli, deps, onProgress) {
5605
5583
  };
5606
5584
  return runSteps(plan.steps, deps, onProgress);
5607
5585
  }
5608
- const BINARIES = {
5609
- claude: ["claude"],
5610
- codex: ["codex"],
5611
- opencode: ["opencode"],
5612
- grok: ["grok"],
5613
- antigravity: ["agy"]
5614
- };
5615
5586
  /** Run `npm prefix -g` and return its first output line. Undefined on any failure. */
5616
5587
  function npmPrefix(deps) {
5617
5588
  const plan = planSpawn(isWin(deps.platform) ? "npm.cmd" : "npm", ["prefix", "-g"], {
@@ -5650,18 +5621,19 @@ function npmPrefix(deps) {
5650
5621
  async function extraDirs(cli, deps) {
5651
5622
  const w = isWin(deps.platform);
5652
5623
  const p = w ? win32 : posix;
5653
- const local = p.join(deps.home, ".local", "bin");
5654
- switch (cli) {
5655
- case "claude": return [local];
5656
- case "antigravity": return w ? [p.join(deps.env.LOCALAPPDATA || p.join(deps.home, "AppData", "Local"), "agy", "bin")] : [local];
5657
- case "grok": return [p.join(deps.home, ".grok", "bin")];
5658
- case "codex":
5659
- case "opencode": {
5624
+ const out = [];
5625
+ const dirs = CLIS[cli].install.dirs;
5626
+ for (const dir of dirs) {
5627
+ if (dir.from === "npmPrefix") {
5660
5628
  const prefix = await npmPrefix(deps);
5661
- if (!prefix) return [];
5662
- return [w ? prefix : p.join(prefix, "bin")];
5629
+ if (prefix) out.push(w ? prefix : p.join(prefix, "bin"));
5630
+ continue;
5663
5631
  }
5632
+ if (dir.only && dir.only !== (w ? "win32" : "posix")) continue;
5633
+ const base = dir.from === "home" ? deps.home : deps.env.LOCALAPPDATA || p.join(deps.home, "AppData", "Local");
5634
+ out.push(p.join(base, ...dir.path));
5664
5635
  }
5636
+ return out;
5665
5637
  }
5666
5638
  /**
5667
5639
  * Where the CLI is after an install: first on the current PATH, then with PATH extended by the
@@ -5669,7 +5641,7 @@ async function extraDirs(cli, deps) {
5669
5641
  */
5670
5642
  async function findAfterInstall(cli, deps) {
5671
5643
  const search = (env) => {
5672
- for (const name of BINARIES[cli]) {
5644
+ for (const name of CLIS[cli].binaries) {
5673
5645
  const hit = findOnPath(name, env, deps.platform, deps.isFile);
5674
5646
  if (hit) return hit;
5675
5647
  }
@@ -5957,21 +5929,9 @@ function setHelpers(ctx, on) {
5957
5929
  }
5958
5930
  // src/tui/onboarding/copy.ts
5959
5931
  /** The order the tools are listed in. */
5960
- const TOOL_ORDER = [
5961
- "claude",
5962
- "codex",
5963
- "opencode",
5964
- "antigravity",
5965
- "grok"
5966
- ];
5932
+ const TOOL_ORDER = CLI_DESCRIPTORS.map((d) => d.id);
5967
5933
  /** Lowercase short names, as a person would say them in a sentence. */
5968
- const SHORT_NAMES = {
5969
- claude: "claude",
5970
- codex: "codex",
5971
- opencode: "opencode",
5972
- antigravity: "antigravity",
5973
- grok: "grok"
5974
- };
5934
+ const SHORT_NAMES = Object.fromEntries(CLI_DESCRIPTORS.map((d) => [d.id, d.shortName]));
5975
5935
  const toolName = (cli, fallback) => TOOL_NAMES[cli] ?? fallback ?? cli;
5976
5936
  const WELCOME_LINES = ["Your AI coding tools, working as one team.", "One leads, the others pick up the work, even when idle."];
5977
5937
  const installQuestion = (name) => `${name} isn't installed. Install it now? It takes about a minute.`;
@@ -6103,13 +6063,8 @@ const accountIo = (ctx) => ({
6103
6063
  apiBase: loginAccountApi(ctx.env),
6104
6064
  now: () => ctx.now().getTime()
6105
6065
  });
6106
- const PROCESS_NAMES = {
6107
- claude: "claude",
6108
- codex: "codex",
6109
- opencode: "opencode",
6110
- antigravity: "agy",
6111
- grok: "grok"
6112
- };
6066
+ /** The name of a CLI's window process: its first binary (`agy` for Antigravity). */
6067
+ const processName = (cli) => CLIS[cli].binaries[0] ?? cli;
6113
6068
  /** Words in a command line that mark a background server, helper or protocol process, not a window. */
6114
6069
  const SERVER_ARGS = /(?:^|\s)(?:app-server|serve|daemon|mcp|acp|--managed-daemon|--service)(?=\s|$)/i;
6115
6070
  /**
@@ -6148,7 +6103,7 @@ function openTools(processes, clis) {
6148
6103
  const parts = splitCommand(p.command);
6149
6104
  if (parts && !SERVER_ARGS.test(parts.args)) open.add(parts.name);
6150
6105
  }
6151
- return clis.filter((c) => open.has(PROCESS_NAMES[c]));
6106
+ return clis.filter((c) => open.has(processName(c)));
6152
6107
  }
6153
6108
  async function runningTools(ctx, clis) {
6154
6109
  try {
@@ -4,31 +4,16 @@ import { homedir } from "node:os";
4
4
  import { delimiter, join, win32 } from "node:path";
5
5
  import { createInterface } from "node:readline";
6
6
  import { fileURLToPath } from "node:url";
7
- import { n as antigravityAdapter } from "./dist-CTw3arJP.js";
8
- import { a as opencodeAdapter, o as claudeAdapter, r as readAllStdin } from "./hook-entry-DYXjVztc.js";
9
- import { t as codexAdapter } from "./dist-CvKAege3.js";
10
- import { t as grokAdapter } from "./dist-Bb2opAjB.js";
11
7
  import { t as createTheme } from "./dist-BOwFdixw.js";
12
- import { n as connect$1 } from "./dist-BgAfkqeX.js";
13
- import { $t as realSpawnDeps, En as validateRename, Et as needsQuoting, Fn as CLI_KINDS, G as detectRepo, H as dataPaths, Hn as MessageId, It as pendingTurn, Kt as readAncestry, Lt as pidAlive, Mt as parsePs1ShimTarget, O as baseName, T as attachAcpSession, Un as OWNER_SESSION_ID, V as dataDir, Vt as planSpawn, Yt as readModelMenus, Zn as SessionId, _t as launcherText, a as HEARTBEAT_INTERVAL_MS, f as SpawnError, gn as spawnSession, gr as boolean, gt as launcherPath, hr as array, j as claimSpawnRecord, jt as parseCmdShimTarget, mr as _enum, o as NOT_FROM_USER_NOTICE, qn as RpcErrorCode, qt as readCommandLine, r as ConvenoError, rt as formatInbox, sn as resolveWindowsCommand, u as SPAWN_CLIS, ut as isAntigravityApp, xr as string, yr as number } from "./dist-Dc50_P_f.js";
14
- import "./dist-B1pfP_d5.js";
8
+ import { n as connect } from "./dist-DAVtixeC.js";
9
+ import { $t as readModelMenus, A as baseName, An as validateRename, At as needsQuoting, Bt as pendingTurn, Cr as number, D as attachAcpSession, Ft as parseCmdShimTarget, G as dataDir, Gt as planSpawn, It as parsePs1ShimTarget, K as dataPaths, Kn as MessageId, L as cliDescriptor, N as claimSpawnRecord, Tr as string, Vt as pidAlive, Xt as readAncestry, Y as detectRepo, Zn as RpcErrorCode, Zt as readCommandLine, a as ConvenoError, bn as spawnSession, br as boolean, bt as launcherPath, c as NOT_FROM_USER_NOTICE, dn as resolveWindowsCommand, f as SPAWN_CLIS, m as SpawnError, mt as isAntigravityApp, rn as realSpawnDeps, s as HEARTBEAT_INTERVAL_MS, st as formatInbox, tr as SessionId, vr as _enum, xt as launcherText, yr as array, zn as CLI_KINDS } from "./dist-CSSvrcKr.js";
10
+ import { t as defaultIsAlive } from "./dist-DV9DhvJC.js";
15
11
  import { access } from "node:fs/promises";
16
12
  import { McpServer } from "@modelcontextprotocol/sdk/server/mcp.js";
17
13
  import { StdioServerTransport } from "@modelcontextprotocol/sdk/server/stdio.js";
18
- // ../daemon/dist/server-B-6PHvmV.js
19
- /** `kill(pid, 0)` liveness: EPERM means the process exists but belongs to someone else. */
20
- function defaultIsAlive(pid) {
21
- try {
22
- process.kill(pid, 0);
23
- return true;
24
- } catch (e) {
25
- return e.code === "EPERM";
26
- }
27
- }
28
- `${OWNER_SESSION_ID}`;
29
- SessionId.parse("0".repeat(26));
14
+ import { a as adapterList, r as readAllStdin } from "./hook-entry-BwzBtAnd.js";
30
15
  // ../mcp/dist/index.js
31
- const SERVER_VERSION = "0.2.0-rc.17";
16
+ const SERVER_VERSION = "0.2.0-rc.18";
32
17
  const MENU_NAMES_MAX = 12;
33
18
  /**
34
19
  * One sentence for the spawn_session description: the models and efforts each CLI offered the
@@ -314,12 +299,12 @@ function createServer(opts) {
314
299
  actingId = void 0;
315
300
  };
316
301
  /**
317
- * The conversation a tool call comes from, in the request's `_meta`: Codex `threadId`, OpenCode
318
- * `ai.opencode/sessionID`, Antigravity `antigravity.google/root_conversation_id`.
302
+ * The conversation a tool call comes from, in the request's `_meta` key the CLI's descriptor
303
+ * names (`conversationMetaKey`): Codex `threadId`, OpenCode `ai.opencode/sessionID`.
319
304
  */
320
305
  const conversationOf = (extra) => {
321
306
  const meta = extra?._meta;
322
- const key = cli === "codex" ? "threadId" : cli === "opencode" ? "ai.opencode/sessionID" : cli === "antigravity" ? "antigravity.google/root_conversation_id" : void 0;
307
+ const key = cliDescriptor(cli)?.conversationMetaKey;
323
308
  const v = key === void 0 ? void 0 : meta?.[key];
324
309
  return typeof v === "string" && v.length > 0 && v.length <= 256 ? v : void 0;
325
310
  };
@@ -553,7 +538,7 @@ async function runStdio(opts) {
553
538
  hostPids: a.pids,
554
539
  variant: opts.cli === "antigravity" && isAntigravityApp(a.entries) ? "app" : void 0
555
540
  }));
556
- const client = await connect$1({
541
+ const client = await connect({
557
542
  kind: "mcp",
558
543
  autoStart: true,
559
544
  ...opts.daemonEntry ? { daemonEntry: opts.daemonEntry } : {}
@@ -812,13 +797,7 @@ function createRuntimeCtx() {
812
797
  bin: cliBinPath(),
813
798
  launcher: convenoLauncher(env, platform, dir, void 0, void 0, void 0, home)
814
799
  },
815
- adapters: [
816
- claudeAdapter,
817
- codexAdapter,
818
- opencodeAdapter,
819
- antigravityAdapter,
820
- grokAdapter
821
- ],
800
+ adapters: adapterList(),
822
801
  spawnRunner: [process.execPath, cliBinPath()],
823
802
  exec,
824
803
  theme,
@@ -829,7 +808,7 @@ function createRuntimeCtx() {
829
808
  prompt: (q) => promptLine(theme, q),
830
809
  now: () => /* @__PURE__ */ new Date(),
831
810
  readStdin: readAllStdin,
832
- connect: connect$1,
811
+ connect,
833
812
  ancestry: (timeoutMs) => readAncestry({
834
813
  timeoutMs,
835
814
  launcherPaths: process.argv[1] ? [process.argv[1]] : []
@@ -1,8 +1,8 @@
1
- import { An as workerAskTimeoutOf, Fn as CLI_KINDS, Gt as readAccountTokens, H as dataPaths, Ht as pollDeviceCode, I as compatStatus, L as completeLogin, Pn as writeSettings, Q as fetchAccountStatus, Rt as pinnedAdapter, St as logoutAccount, Vt as planSpawn, Zt as readSettings, an as resolveAcpProgram, b as adapterNpxCommand, d as SPAWN_TABLE, et as findOnPath, jn as workerUnansweredOf, kn as workerAccessOf, nn as requestDeviceCode, p as WORKER_ACCESS, pn as signedInAccountApi, t as AccountError, v as acpOverrideVar, xt as loginAccountApi, y as adapterInstallCommand } from "./dist-Dc50_P_f.js";
1
+ import { B as compatStatus, Et as logoutAccount, Fn as workerUnansweredOf, Gt as planSpawn, Ht as pinnedAdapter, K as dataPaths, Kt as pollDeviceCode, Nn as workerAccessOf, Pn as workerAskTimeoutOf, Rn as writeSettings, S as adapterNpxCommand, Tt as loginAccountApi, V as completeLogin, Yt as readAccountTokens, _n as signedInAccountApi, b as acpOverrideVar, h as WORKER_ACCESS, it as findOnPath, ln as resolveAcpProgram, nt as fetchAccountStatus, on as requestDeviceCode, p as SPAWN_TABLE, t as AccountError, tn as readSettings, x as adapterInstallCommand, zn as CLI_KINDS } from "./dist-CSSvrcKr.js";
2
2
  import { a as fail, c as plural, d as warnBlock, i as errorBlock, l as seconds, n as cmd, o as localStamp, r as columns, s as plainError, t as closest, u as tilde } from "./fmt-C2SsP5Y0.js";
3
3
  import { a as parseFlags, n as COMMANDS } from "./args-CtyKPZuN.js";
4
4
  import { n as connectOpts, t as adapterEnv } from "./ctx-tYftvhz_.js";
5
- import { t as daemonProblem } from "./daemonError-BwdtKOCy.js";
5
+ import { t as daemonProblem } from "./daemonError-CDgEtvy7.js";
6
6
  import { basename, dirname, isAbsolute, join } from "node:path";
7
7
  import { execFile, spawn } from "node:child_process";
8
8
  import { access, chmod, mkdir, open, readFile, readdir, realpath, rename as rename$1, rm, rmdir, stat, writeFile } from "node:fs/promises";
@@ -145,7 +145,7 @@ async function runAccount(ctx, argv, io = {}) {
145
145
  }
146
146
  }
147
147
  // src/version.ts
148
- const VERSION = "0.2.0-rc.17";
148
+ const VERSION = "0.2.0-rc.18";
149
149
  // src/daemon.ts
150
150
  async function lockPid(ctx) {
151
151
  try {
@@ -1934,7 +1934,7 @@ async function runSetup(ctx, argv) {
1934
1934
  });
1935
1935
  if (ctx.interactive && v.yes !== true && v["dry-run"] !== true) {
1936
1936
  if (isWorkerAccess(access)) saveWorkerAccess(ctx, { access });
1937
- return (await import("./run-B01nDeos.js")).runTui(ctx, { start: "setup" });
1937
+ return (await import("./run-BtYGSOMi.js")).runTui(ctx, { start: "setup" });
1938
1938
  }
1939
1939
  return runInit(ctx, argv, "setup");
1940
1940
  }
@@ -1,8 +1,8 @@
1
- import { n as isOneShotGrok } from "./dist-Bb2opAjB.js";
2
- import { dt as isFromOwner, fn as senderOf, tn as renderBody, un as runWaker } from "./dist-Dc50_P_f.js";
1
+ import { n as isOneShotGrok } from "./dist-CFsDqevs.js";
2
+ import { an as renderBody, gn as senderOf, ht as isFromOwner, mn as runWaker } from "./dist-CSSvrcKr.js";
3
3
  import { n as connectOpts } from "./ctx-tYftvhz_.js";
4
- import { t as daemonProblem } from "./daemonError-BwdtKOCy.js";
5
- import { t as findSession } from "./pick-iuG24FX9.js";
4
+ import { t as daemonProblem } from "./daemonError-CDgEtvy7.js";
5
+ import { t as findSession } from "./pick-BsMvXuDo.js";
6
6
  // src/watch.ts
7
7
  const CONNECT_MAX_RETRY_MS = 3e4;
8
8
  const CONNECT_GIVE_UP_MS = 3e5;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@conveno/cli",
3
- "version": "0.2.0-rc.17",
3
+ "version": "0.2.0-rc.18",
4
4
  "description": "Connect AI coding CLI sessions so they can message each other.",
5
5
  "license": "Apache-2.0",
6
6
  "repository": {
@@ -53,18 +53,18 @@
53
53
  "zod": "4.6.7"
54
54
  },
55
55
  "devDependencies": {
56
- "@conveno/acp": "0.2.0-rc.17",
57
- "@conveno/adapter-antigravity": "0.2.0-rc.17",
58
- "@conveno/adapter-claude": "0.2.0-rc.17",
59
- "@conveno/adapter-codex": "0.2.0-rc.17",
60
- "@conveno/adapter-grok": "0.2.0-rc.17",
61
- "@conveno/adapter-opencode": "0.2.0-rc.17",
62
- "@conveno/brand": "0.2.0-rc.17",
63
- "@conveno/client": "0.2.0-rc.17",
64
- "@conveno/core": "0.2.0-rc.17",
65
- "@conveno/daemon": "0.2.0-rc.17",
66
- "@conveno/mcp": "0.2.0-rc.17",
67
- "@conveno/protocol": "0.2.0-rc.17",
56
+ "@conveno/acp": "0.2.0-rc.18",
57
+ "@conveno/adapter-antigravity": "0.2.0-rc.18",
58
+ "@conveno/adapter-claude": "0.2.0-rc.18",
59
+ "@conveno/adapter-codex": "0.2.0-rc.18",
60
+ "@conveno/adapter-grok": "0.2.0-rc.18",
61
+ "@conveno/adapter-opencode": "0.2.0-rc.18",
62
+ "@conveno/brand": "0.2.0-rc.18",
63
+ "@conveno/client": "0.2.0-rc.18",
64
+ "@conveno/core": "0.2.0-rc.18",
65
+ "@conveno/daemon": "0.2.0-rc.18",
66
+ "@conveno/mcp": "0.2.0-rc.18",
67
+ "@conveno/protocol": "0.2.0-rc.18",
68
68
  "@types/react": "19.3.0",
69
69
  "ink-testing-library": "4.0.0"
70
70
  },