codeam-cli 2.19.0 → 2.20.0

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,85 @@ 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.19.0] — 2026-05-24
8
+
9
+ ### Added
10
+
11
+ - **both-plugins:** PostHog telemetry, mirrors the CLI (closes #95) (#142)
12
+ - **both-plugins:** Bundle Hanken Grotesk + JetBrains Mono fonts (closes #96) (#147)
13
+ - **vsc-plugin:** Add Copy Install Command CTA to empty agents state (closes #116) (#166)
14
+ - **vsc-plugin:** 3-state status bar with rich Markdown tooltip (closes #115) (#167)
15
+ - **both-plugins:** All-detector agent discovery; enable cursor/coderabbit/aider (closes #102 follow-up) (#171)
16
+ - **both-plugins:** A11y pass — ARIA, focus rings, mnemonics, focus order (closes #106) (#172)
17
+ - **both-plugins:** FooterStatusStrip — at-a-glance connection summary (closes #114) (#174)
18
+ - **vsc-plugin:** Brand polish — GlassCard + cyberpunk h3 voice (closes #79) (#175)
19
+
20
+ ### CI
21
+
22
+ - Drop node 18 + skip Vitest on Windows + advisory backend probes (#128)
23
+
24
+ ### Changed
25
+
26
+ - **vsc-plugin:** Split controller-panel.ts (partial #89) (#143)
27
+ - **jetbrains-plugin:** Extract RemoteCommandRouter (partial #89) (#144)
28
+ - **jetbrains-plugin:** Split AgentOutputMonitor — publisher + text utils (partial #89) (#145)
29
+ - **both-plugins:** Remove dead WebSocketService + AgentBridgeService (closes #90) (#149)
30
+ - **jetbrains-plugin:** Extract RoundedPanel + DeviceConnectionPanel (further #89) (#151)
31
+ - **jetbrains-plugin:** Split TerminalAgentService — publisher + reader (further #89) (#152)
32
+ - **jetbrains-plugin:** Extract Swing-walk helpers from AgentOutputMonitor (further #89) (#153)
33
+ - **jetbrains-plugin:** Extract Cascade JS + Codeium process tap (further #89) (#154)
34
+ - **jetbrains-plugin:** Extract AIAssistant text-extraction helpers (further #89) (#155)
35
+ - **jetbrains-plugin:** Extract JcefCaptureState from AgentOutputMonitor (closes #89 follow-up) (#156)
36
+ - **jetbrains-plugin:** Split ControllerPanel HTTP + QR + row factory (closes #89 follow-up) (#157)
37
+ - **shared:** Centralize PROTOCOL_VERSION + lifecycle constants (closes #97) (#164)
38
+ - **both-plugins:** Lock notification voice to canonical CodeAgent Mobile copy (closes #105) (#165)
39
+ - **vsc-plugin:** Deprecate Claude PTY-directo + Claude handlers (closes #102) (#169)
40
+ - **jetbrains-plugin:** Deprecate Claude PTY-directo + handlers (closes #102) (#170)
41
+
42
+ ### Chore
43
+
44
+ - **jetbrains-plugin:** Delete dead RobotPasteStrategy (partial #90) (#139)
45
+ - **workflow:** Delete release-single.yml — drift surface (closes #110) (#158)
46
+ - **both-plugins:** Wire logger.trace into every empty catch (closes #111) (#173)
47
+
48
+ ### Fixed
49
+
50
+ - **ci:** Smoke test reads stderr too — banners moved off stdout in v2.18.x
51
+ - **vsc-plugin:** Add webview CSP + render QR locally (closes #70) (#117)
52
+ - **both-plugins:** Store pluginAuthToken in SecretStorage / PasswordSafe (closes #71) (#118)
53
+ - **vsc-plugin:** Authenticate the observer-bridge on 127.0.0.1:47832 (closes #72) (#119)
54
+ - **vsc-plugin:** Realpath candidate + workspace before sandbox check (closes #73) (#120)
55
+ - **vsc-plugin:** Gate workbench-injection cleanup behind a one-shot flag (closes #74) (#121)
56
+ - **jetbrains-plugin:** Drop untilBuild cap + re-enable plugin-structure warnings (closes #76) (#122)
57
+ - **jetbrains-plugin:** Adopt CodeAgent Mobile brand palette + drop stale strings (closes #80) (#123)
58
+ - **jetbrains-plugin:** Lift resume_session 500ms sleeps off EDT + WS reader (partial #75) (#124)
59
+ - **jetbrains-plugin:** Surface action group under Tools menu (closes #77) (#125)
60
+ - **both-plugins:** 401 recovery — clear token, stop transports, surface re-pair UX (closes #78) (#126)
61
+ - **vsc-plugin:** Adopt CodeAgent brand palette in webview (partial #79) (#127)
62
+ - **cli:** Make tests + parser cross-platform; restore Windows in CI (#129)
63
+ - **both-plugins:** Align clearRemoteOutput on CLI wire shape (closes #83) (#130)
64
+ - **both-plugins:** Honor heartbeatIntervalMs setting in CommandRelayService (closes #84) (#131)
65
+ - **both-plugins:** Cap base64 attachments at 10 MB (closes #92) (#132)
66
+ - **both-plugins:** Refuse to overwrite malformed MCP config (closes #93) (#133)
67
+ - **vsc-plugin:** Exclude .pdb + tests from .vsix (closes #86) (#134)
68
+ - **both-plugins:** De-dup commands by id on SSE reconnect (closes #85) (#135)
69
+ - **both-plugins:** Surface a 3-state Connected/Reconnecting/Offline dot (closes #94) (#136)
70
+ - **both-plugins:** Align strategy contract — same fields + StrategyResult (closes #82) (#137)
71
+ - **vsc-plugin:** Defer eager activation work to first pair (closes #87) (#138)
72
+ - **both-plugins:** Align command-handler surface (closes #81) (#140)
73
+ - **vsc-plugin:** Drop Python PTY helper, route Claude through node-pty (closes #88) (#146)
74
+ - **jetbrains-plugin:** Lift remaining EDT-blocking sites in dispatch (closes #75) (#150)
75
+ - **jetbrains-plugin:** Multi-IDE verifier matrix + dynamic-plugin marker (closes #100, #108) (#159)
76
+ - **jetbrains-plugin:** Track all known projects in IdeIntegrationService (closes #99) (#160)
77
+ - **vsc-plugin:** Per-window port + per-workspace pluginId (closes #103) (#161)
78
+ - **vsc-plugin:** Cache SettingsService config + react to mid-session changes (closes #107) (#162)
79
+ - **vsc-plugin:** Drop \`as unknown as Record<string, unknown>\` casts (closes #104) (#163)
80
+
81
+ ### Tests
82
+
83
+ - **vsc-plugin:** Cover webview-security helpers + extract sanitizeSessionId (partial #91) (#141)
84
+ - **vsc-plugin:** Cover CommandRelayService dispatch + dedup + state (closes #91) (#148)
85
+
7
86
  ## [2.18.2] — 2026-05-24
8
87
 
9
88
  ### Fixed
package/dist/index.js CHANGED
@@ -316,6 +316,15 @@ function isKnownAgentId(id) {
316
316
 
317
317
  // ../../packages/shared/src/api-url.ts
318
318
  var DEFAULT_API_BASE_URL = "https://api.codeagent-mobile.com";
319
+ var DEV_API_BASE_URL = "https://dev-api.codeagent-mobile.com";
320
+ function resolveApiBaseUrl() {
321
+ const env = globalThis.process?.env;
322
+ const explicit = env?.CODEAM_API_URL?.trim();
323
+ if (explicit) return explicit;
324
+ const testFlag = env?.CODEAM_TEST_MODE?.trim();
325
+ if (testFlag === "1" || testFlag?.toLowerCase() === "true") return DEV_API_BASE_URL;
326
+ return DEFAULT_API_BASE_URL;
327
+ }
319
328
 
320
329
  // src/config.ts
321
330
  var fs = __toESM(require("fs"));
@@ -432,7 +441,7 @@ var import_qrcode_terminal = __toESM(require("qrcode-terminal"));
432
441
  // package.json
433
442
  var package_default = {
434
443
  name: "codeam-cli",
435
- version: "2.19.0",
444
+ version: "2.20.0",
436
445
  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.",
437
446
  type: "commonjs",
438
447
  main: "dist/index.js",
@@ -619,7 +628,7 @@ function computePollDelay({ baseMs, failures }) {
619
628
  }
620
629
 
621
630
  // src/services/pairing.service.ts
622
- var API_BASE = process.env.CODEAM_API_URL ?? DEFAULT_API_BASE_URL;
631
+ var API_BASE = resolveApiBaseUrl();
623
632
  async function requestCode(pluginId) {
624
633
  try {
625
634
  const runtime = process.env.CODESPACES === "true" ? "github-codespaces" : "local";
@@ -5731,7 +5740,7 @@ function readAnonId() {
5731
5740
  }
5732
5741
  function superProperties() {
5733
5742
  return {
5734
- cliVersion: true ? "2.19.0" : "0.0.0-dev",
5743
+ cliVersion: true ? "2.20.0" : "0.0.0-dev",
5735
5744
  nodeVersion: process.version,
5736
5745
  platform: process.platform,
5737
5746
  arch: process.arch,
@@ -5822,7 +5831,7 @@ function maybePrintFirstRunBanner() {
5822
5831
  }
5823
5832
 
5824
5833
  // src/services/command-relay.service.ts
5825
- var API_BASE2 = process.env.CODEAM_API_URL ?? DEFAULT_API_BASE_URL;
5834
+ var API_BASE2 = resolveApiBaseUrl();
5826
5835
  var CommandRelayService = class {
5827
5836
  constructor(pluginId, onCommand, agentMeta) {
5828
5837
  this.pluginId = pluginId;
@@ -11157,7 +11166,7 @@ var ChromeStepTracker = class {
11157
11166
  // src/services/output/chunk-emitter.ts
11158
11167
  var https3 = __toESM(require("https"));
11159
11168
  var http3 = __toESM(require("http"));
11160
- var API_BASE3 = process.env.CODEAM_API_URL ?? DEFAULT_API_BASE_URL;
11169
+ var API_BASE3 = resolveApiBaseUrl();
11161
11170
  var ChunkEmitter = class {
11162
11171
  constructor(opts) {
11163
11172
  this.opts = opts;
@@ -11662,7 +11671,7 @@ var historyRecordSchema = import_zod.z.object({
11662
11671
  content: import_zod.z.union([import_zod.z.string(), import_zod.z.array(import_zod.z.unknown())]).optional()
11663
11672
  }).passthrough().optional()
11664
11673
  }).passthrough();
11665
- var API_BASE4 = process.env.CODEAM_API_URL ?? DEFAULT_API_BASE_URL;
11674
+ var API_BASE4 = resolveApiBaseUrl();
11666
11675
  function extractText2(content) {
11667
11676
  if (typeof content === "string") return content;
11668
11677
  if (Array.isArray(content)) {
@@ -12269,7 +12278,7 @@ function _post2(url, headers, payload) {
12269
12278
  }
12270
12279
 
12271
12280
  // src/services/file-watcher.service.ts
12272
- var API_BASE5 = process.env.CODEAM_API_URL ?? DEFAULT_API_BASE_URL;
12281
+ var API_BASE5 = resolveApiBaseUrl();
12273
12282
  var DEBOUNCE_MS = 250;
12274
12283
  var MAX_RETRIES = 2;
12275
12284
  var RETRY_BACKOFF_MS = 300;
@@ -12745,7 +12754,7 @@ function _get(url, headers) {
12745
12754
  }
12746
12755
 
12747
12756
  // src/services/streaming-emitter.service.ts
12748
- var API_BASE6 = process.env.CODEAM_API_URL ?? DEFAULT_API_BASE_URL;
12757
+ var API_BASE6 = resolveApiBaseUrl();
12749
12758
  var TICK_MS = 50;
12750
12759
  var ANSWER_POLL_MS = 1500;
12751
12760
  var SELECTOR_STABLE_MS = 800;
@@ -14617,7 +14626,7 @@ async function pair(args2 = []) {
14617
14626
  var fs24 = __toESM(require("fs"));
14618
14627
  var os24 = __toESM(require("os"));
14619
14628
  var import_crypto6 = require("crypto");
14620
- var API_BASE7 = process.env.CODEAM_API_URL ?? DEFAULT_API_BASE_URL;
14629
+ var API_BASE7 = resolveApiBaseUrl();
14621
14630
  function fail(msg) {
14622
14631
  console.error(`
14623
14632
  ${msg}
@@ -14847,7 +14856,7 @@ function status() {
14847
14856
 
14848
14857
  // src/commands/logout.ts
14849
14858
  var import_picocolors6 = __toESM(require("picocolors"));
14850
- var API_BASE8 = process.env.CODEAM_API_URL ?? DEFAULT_API_BASE_URL;
14859
+ var API_BASE8 = resolveApiBaseUrl();
14851
14860
  async function notifyBackendOffline() {
14852
14861
  const cfg = loadCliConfig();
14853
14862
  const pluginIds = /* @__PURE__ */ new Set([
@@ -17321,8 +17330,8 @@ function checkChokidar() {
17321
17330
  }
17322
17331
  async function doctor(args2 = []) {
17323
17332
  const json = args2.includes("--json");
17324
- const cliVersion = true ? "2.19.0" : "0.0.0-dev";
17325
- const apiBase = process.env.CODEAM_API_URL ?? DEFAULT_API_BASE_URL;
17333
+ const cliVersion = true ? "2.20.0" : "0.0.0-dev";
17334
+ const apiBase = resolveApiBaseUrl();
17326
17335
  const diagnosticId = (0, import_node_crypto5.randomUUID)();
17327
17336
  log.info("doctor", `run id=${diagnosticId} cli=${cliVersion}`);
17328
17337
  const [dns, health] = await Promise.all([
@@ -17372,6 +17381,13 @@ ${import_picocolors12.default.bold(" codeam doctor")}
17372
17381
  `);
17373
17382
  out2.write(` ${import_picocolors12.default.dim("api")} ${r.apiBase}
17374
17383
  `);
17384
+ if (process.env.CODEAM_TEST_MODE === "1" || process.env.CODEAM_TEST_MODE?.toLowerCase() === "true") {
17385
+ out2.write(` ${import_picocolors12.default.dim("mode")} ${import_picocolors12.default.yellow("TEST_MODE \u2014 using dev preview")}
17386
+ `);
17387
+ } else if (process.env.CODEAM_API_URL) {
17388
+ out2.write(` ${import_picocolors12.default.dim("mode")} ${import_picocolors12.default.yellow("CODEAM_API_URL override")}
17389
+ `);
17390
+ }
17375
17391
  out2.write(` ${import_picocolors12.default.dim("diag id")} ${r.diagnosticId}
17376
17392
  `);
17377
17393
  out2.write("\n");
@@ -17513,7 +17529,7 @@ async function completion(args2) {
17513
17529
  // src/commands/version.ts
17514
17530
  var import_picocolors13 = __toESM(require("picocolors"));
17515
17531
  function version2() {
17516
- const v = true ? "2.19.0" : "unknown";
17532
+ const v = true ? "2.20.0" : "unknown";
17517
17533
  console.log(`${import_picocolors13.default.bold("codeam-cli")} ${import_picocolors13.default.cyan(v)}`);
17518
17534
  }
17519
17535
 
@@ -17741,7 +17757,7 @@ function checkForUpdates() {
17741
17757
  if (process.env.CODEAM_DISABLE_UPDATE_CHECK === "1") return;
17742
17758
  if (process.env.CI) return;
17743
17759
  if (!process.stdout.isTTY) return;
17744
- const current = true ? "2.19.0" : null;
17760
+ const current = true ? "2.20.0" : null;
17745
17761
  if (!current) return;
17746
17762
  const cache = readCache();
17747
17763
  const fresh = cache && Date.now() - cache.fetchedAt < TTL_MS;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "codeam-cli",
3
- "version": "2.19.0",
3
+ "version": "2.20.0",
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",