codeam-cli 2.39.20 → 2.39.22

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/CHANGELOG.md CHANGED
@@ -4,6 +4,18 @@ All notable changes to `codeam-cli` are documented here.
4
4
 
5
5
  The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
6
6
 
7
+ ## [2.39.21] — 2026-06-16
8
+
9
+ ### Fixed
10
+
11
+ - **cli:** Serialize onboarding welcome before the command relay starts (#343)
12
+
13
+ ## [2.39.20] — 2026-06-15
14
+
15
+ ### Fixed
16
+
17
+ - **cli:** Handle ACP adapter spawn errors instead of crashing the relay
18
+
7
19
  ## [2.39.19] — 2026-06-15
8
20
 
9
21
  ### Fixed
package/dist/index.js CHANGED
@@ -498,7 +498,7 @@ var import_qrcode_terminal = __toESM(require("qrcode-terminal"));
498
498
  // package.json
499
499
  var package_default = {
500
500
  name: "codeam-cli",
501
- version: "2.39.20",
501
+ version: "2.39.22",
502
502
  description: "Workflow-continuity bridge for AI coding agents. Wrap Claude Code or Codex in a PTY and supervise, approve, and redirect the session from any device \u2014 async. The terminal companion for CodeAgent Mobile.",
503
503
  type: "commonjs",
504
504
  main: "dist/index.js",
@@ -5908,7 +5908,7 @@ function readAnonId() {
5908
5908
  }
5909
5909
  function superProperties() {
5910
5910
  return {
5911
- cliVersion: true ? "2.39.20" : "0.0.0-dev",
5911
+ cliVersion: true ? "2.39.22" : "0.0.0-dev",
5912
5912
  nodeVersion: process.version,
5913
5913
  platform: process.platform,
5914
5914
  arch: process.arch,
@@ -15451,7 +15451,7 @@ function buildOnboardingWelcome(cwd) {
15451
15451
  `Ready when you are \u2014 try **"explain ${repo}"** or **"what should I work on first?"**`
15452
15452
  ].join("\n");
15453
15453
  }
15454
- function maybeSendOnboardingWelcome(opts) {
15454
+ async function maybeSendOnboardingWelcome(opts) {
15455
15455
  if (_onboardingSeam.disabled()) return;
15456
15456
  const marker = _onboardingSeam.markerPath(opts.sessionId);
15457
15457
  try {
@@ -15462,17 +15462,19 @@ function maybeSendOnboardingWelcome(opts) {
15462
15462
  return;
15463
15463
  }
15464
15464
  log.info("acpRunner", `sending first-pair onboarding welcome for session=${opts.sessionId.slice(0, 8)}`);
15465
- void runOnboardingTurn(opts).catch((err) => {
15465
+ try {
15466
+ await runOnboardingTurn(opts);
15467
+ } catch (err) {
15466
15468
  log.warn(
15467
15469
  "acpRunner",
15468
15470
  `onboarding welcome turn failed (non-fatal): ${err instanceof Error ? err.message : String(err)}`
15469
15471
  );
15470
- });
15472
+ }
15471
15473
  }
15472
15474
  async function runOnboardingTurn(opts) {
15473
15475
  const { streaming, history, cwd } = opts;
15474
15476
  const welcome = buildOnboardingWelcome(cwd);
15475
- await streaming.beginTurn();
15477
+ await streaming.beginTurn({ clear: false });
15476
15478
  try {
15477
15479
  streaming.append({ chunkId: "onboarding-welcome", kind: "text", delta: welcome });
15478
15480
  await streaming.closeAll();
@@ -21434,14 +21436,16 @@ var StreamingState = class {
21434
21436
  getCurrentText() {
21435
21437
  return this.text;
21436
21438
  }
21437
- async beginTurn() {
21439
+ async beginTurn(opts) {
21438
21440
  this.text = "";
21439
21441
  this.streamingChunks.clear();
21440
21442
  if (this.pending?.kind === "permission") {
21441
21443
  clearTimeout(this.pending.timeoutTimer);
21442
21444
  }
21443
21445
  this.pending = null;
21444
- await this.publisher.publishOutput({ type: "clear" });
21446
+ if (opts?.clear !== false) {
21447
+ await this.publisher.publishOutput({ type: "clear" });
21448
+ }
21445
21449
  await this.publisher.publishOutput({ type: "new_turn", done: false });
21446
21450
  }
21447
21451
  append(delta) {
@@ -21762,7 +21766,7 @@ async function runAcpSession(opts) {
21762
21766
  const runtime = createInteractiveAgentStrategy(opts.agent, createOsStrategy());
21763
21767
  const models = await runtime.listModels();
21764
21768
  const history = new AcpHistory(publisher, { agent: opts.agent, acpSessionId });
21765
- maybeSendOnboardingWelcome({
21769
+ const onboardingWelcomeDone = maybeSendOnboardingWelcome({
21766
21770
  streaming,
21767
21771
  history,
21768
21772
  sessionId: opts.sessionId,
@@ -21821,6 +21825,7 @@ async function runAcpSession(opts) {
21821
21825
  },
21822
21826
  { id: opts.agent, name: opts.agent, displayName: opts.agent }
21823
21827
  );
21828
+ await onboardingWelcomeDone;
21824
21829
  relay.start();
21825
21830
  const prewarmTimer = setTimeout(() => prewarmPreviewDetection(runtime), 2e4);
21826
21831
  const shutdown = async (signal) => {
@@ -27064,7 +27069,7 @@ function checkChokidar() {
27064
27069
  }
27065
27070
  async function doctor(args2 = []) {
27066
27071
  const json = args2.includes("--json");
27067
- const cliVersion = true ? "2.39.20" : "0.0.0-dev";
27072
+ const cliVersion = true ? "2.39.22" : "0.0.0-dev";
27068
27073
  const apiBase = resolveApiBaseUrl();
27069
27074
  const diagnosticId = (0, import_node_crypto8.randomUUID)();
27070
27075
  log.info("doctor", `run id=${diagnosticId} cli=${cliVersion}`);
@@ -27263,7 +27268,7 @@ async function completion(args2) {
27263
27268
  // src/commands/version.ts
27264
27269
  var import_picocolors13 = __toESM(require("picocolors"));
27265
27270
  function version2() {
27266
- const v = true ? "2.39.20" : "unknown";
27271
+ const v = true ? "2.39.22" : "unknown";
27267
27272
  console.log(`${import_picocolors13.default.bold("codeam-cli")} ${import_picocolors13.default.cyan(v)}`);
27268
27273
  }
27269
27274
 
@@ -27549,7 +27554,7 @@ function checkForUpdates() {
27549
27554
  if (process.env.CODEAM_DISABLE_UPDATE_CHECK === "1") return;
27550
27555
  if (process.env.CI) return;
27551
27556
  if (!process.stdout.isTTY) return;
27552
- const current = true ? "2.39.20" : null;
27557
+ const current = true ? "2.39.22" : null;
27553
27558
  if (!current) return;
27554
27559
  const cache = readCache();
27555
27560
  const fresh = cache && Date.now() - cache.fetchedAt < TTL_MS;
@@ -0,0 +1,33 @@
1
+ #!/usr/bin/env node
2
+ "use strict";
3
+
4
+ // src/postinstall.ts
5
+ var c = {
6
+ reset: "\x1B[0m",
7
+ bold: "\x1B[1m",
8
+ dim: "\x1B[2m",
9
+ green: "\x1B[32m",
10
+ cyan: "\x1B[36m",
11
+ violet: "\x1B[35m",
12
+ white: "\x1B[97m"
13
+ };
14
+ var lines = [
15
+ "",
16
+ ` ${c.violet}${c.bold}codeam-cli${c.reset} ${c.dim}\u2014 Claude Code remote control${c.reset}`,
17
+ "",
18
+ ` ${c.dim}1.${c.reset} Pair your phone:`,
19
+ ` ${c.cyan}codeam pair${c.reset}`,
20
+ "",
21
+ ` ${c.dim}2.${c.reset} Launch Claude Code with mobile control:`,
22
+ ` ${c.cyan}codeam${c.reset}`,
23
+ "",
24
+ ` ${c.dim}Other commands:${c.reset}`,
25
+ ` ${c.white}codeam sessions${c.reset} ${c.dim}list paired devices${c.reset}`,
26
+ ` ${c.white}codeam status${c.reset} ${c.dim}show connection info${c.reset}`,
27
+ ` ${c.white}codeam logout${c.reset} ${c.dim}remove all sessions${c.reset}`,
28
+ "",
29
+ ` ${c.dim}Requires Claude Code:${c.reset} ${c.green}npm install -g @anthropic-ai/claude-code${c.reset}`,
30
+ ` ${c.dim}Mobile app:${c.reset} ${c.green}https://www.codeagent-mobile.com${c.reset}`,
31
+ ""
32
+ ];
33
+ process.stdout.write(lines.join("\n") + "\n");
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "codeam-cli",
3
- "version": "2.39.20",
3
+ "version": "2.39.22",
4
4
  "description": "Workflow-continuity bridge for AI coding agents. Wrap Claude Code or Codex in a PTY and supervise, approve, and redirect the session from any device — async. The terminal companion for CodeAgent Mobile.",
5
5
  "type": "commonjs",
6
6
  "main": "dist/index.js",