usebeeline 0.1.248-rc.2 → 0.1.249-rc.3

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/README.md CHANGED
@@ -18,7 +18,7 @@
18
18
  ## What you can do
19
19
 
20
20
  - **Work with shared context.** One Room for your people and your coding agents. Everyone sees the same threads, tasks and decisions.
21
- - **Resolve blocks explicitly.** Answers leave your Tasks list immediately; the implementer clears the block when work can continue. Agents see their open blocks on every turn.
21
+ - **Resolve blocks explicitly.** Answers leave your Tasks list immediately; any member of the thread, person or agent, clears the block when work can continue. Agents see their open blocks on every turn.
22
22
  - **See work as it happens.** Threads show “Ruby is working” until Ruby replies; Stop ends the line and the agent's run, and a failed Stop says so. Completed steps appear live in the existing fold; a lost host connection is shown in the thread.
23
23
  - **Bring any agent.** Connect the coding agent you already run and tag it like a teammate.
24
24
  - **Set up with one prompt.** Paste a single line into your agent and it joins your Workspace.
@@ -59,142 +59,6 @@ var init_update_progress = __esm({
59
59
  }
60
60
  });
61
61
 
62
- // apps/body/dist/self-update-manifest.js
63
- function resolveManifestUrl(env = process.env) {
64
- const override = env.BEELINE_UPDATE_MANIFEST_URL?.trim();
65
- if (override)
66
- return override;
67
- const channel = env.BEELINE_RELEASE_CHANNEL?.trim() || "latest";
68
- if (!["latest", "next"].includes(channel))
69
- throw new Error(`invalid helper release channel: ${channel}`);
70
- return channel === "next" ? "https://usebeeline.app/dl/next/manifest.json" : DEFAULT_UPDATE_MANIFEST_URL;
71
- }
72
- function parseUpdateManifest(raw, platform) {
73
- let parsed;
74
- try {
75
- parsed = JSON.parse(raw);
76
- } catch (error) {
77
- throw new Error(`update manifest is not valid JSON: ${error instanceof Error ? error.message : String(error)}`);
78
- }
79
- if (typeof parsed !== "object" || parsed === null) {
80
- throw new Error("update manifest is not an object");
81
- }
82
- const manifest = parsed;
83
- const bundles = manifest.bundles;
84
- if (typeof bundles !== "object" || bundles === null) {
85
- throw new Error("update manifest has no bundles table");
86
- }
87
- const entry = bundles[platform];
88
- if (typeof entry !== "object" || entry === null) {
89
- throw new Error(`update manifest has no bundle for platform ${platform}`);
90
- }
91
- const bundle = entry;
92
- const file = typeof bundle.file === "string" ? bundle.file : "";
93
- const sha256 = typeof bundle.sha256 === "string" ? bundle.sha256.toLowerCase() : "";
94
- if (!file || !/^[a-z0-9][a-z0-9._-]*$/i.test(file)) {
95
- throw new Error(`update manifest names an unusable bundle file: ${JSON.stringify(bundle.file)}`);
96
- }
97
- if (!/^[0-9a-f]{64}$/.test(sha256)) {
98
- throw new Error(`update manifest carries no usable sha256 for ${platform}`);
99
- }
100
- const sourceCommit = typeof bundle.commit === "string" && bundle.commit ? bundle.commit : typeof manifest.sourceCommit === "string" ? manifest.sourceCommit : void 0;
101
- const version = typeof bundle.version === "string" && bundle.version ? bundle.version : typeof manifest.version === "string" ? manifest.version : void 0;
102
- return {
103
- schemaVersion: typeof manifest.schemaVersion === "number" ? manifest.schemaVersion : 1,
104
- ...sourceCommit ? { sourceCommit } : {},
105
- ...version ? { version } : {},
106
- bundles,
107
- bundle: {
108
- file,
109
- sha256,
110
- ...typeof bundle.bytes === "number" ? { bytes: bundle.bytes } : {},
111
- ...sourceCommit ? { commit: sourceCommit } : {},
112
- ...version ? { version } : {},
113
- ...typeof bundle.node === "string" ? { node: bundle.node } : {}
114
- }
115
- };
116
- }
117
- function compareBundleIdentity(installed, published) {
118
- if (installed?.version && published.version && installed.version !== published.version) {
119
- const installedNewer = versionAtLeast(installed.version, published.version);
120
- const publishedNewer = versionAtLeast(published.version, installed.version);
121
- if (installedNewer && !publishedNewer)
122
- return { kind: "current" };
123
- if (publishedNewer && !installedNewer)
124
- return { kind: "update-available", published };
125
- }
126
- if (installed?.commit && published.commit) {
127
- if (installed.commit === published.commit)
128
- return { kind: "current" };
129
- return { kind: "update-available", published };
130
- }
131
- if (installed?.version && published.version) {
132
- const ordering = compareVersions(installed.version, published.version);
133
- if (ordering > 0)
134
- return { kind: "current" };
135
- if (ordering < 0)
136
- return { kind: "update-available", published };
137
- if (installed.commit && published.commit)
138
- return { kind: "current" };
139
- return { kind: "current" };
140
- }
141
- const missing = [
142
- ...installed?.commit || installed?.version ? [] : ["installed identity"],
143
- ...published.commit || published.version ? [] : ["published identity"]
144
- ];
145
- return {
146
- kind: "indeterminate",
147
- reason: `cannot compare: ${missing.join(" and ")} unknown`
148
- };
149
- }
150
- function compareVersions(a, b) {
151
- const parse = (value) => {
152
- const parts = value.split(/[.+-]/).filter(Boolean);
153
- if (parts.length === 0)
154
- return void 0;
155
- return parts.map((part) => /^\d+$/.test(part) ? Number(part) : part);
156
- };
157
- const left = parse(a);
158
- const right = parse(b);
159
- if (!left || !right)
160
- return a === b ? 0 : a > b ? 1 : -1;
161
- const length = Math.max(left.length, right.length);
162
- for (let index = 0; index < length; index += 1) {
163
- const l = left[index];
164
- const r = right[index];
165
- if (l === void 0)
166
- return -1;
167
- if (r === void 0)
168
- return 1;
169
- if (l === r)
170
- continue;
171
- if (typeof l === "number" && typeof r === "number")
172
- return l > r ? 1 : -1;
173
- return String(l) > String(r) ? 1 : -1;
174
- }
175
- return 0;
176
- }
177
- function versionAtLeast(actual, minimum) {
178
- const parse = (value) => {
179
- const match = /^v?(\d+)\.(\d+)\.(\d+)(?:-rc\.(\d+))?$/.exec(value);
180
- return match ? [...match.slice(1, 4).map(Number), match[4] === void 0 ? Infinity : Number(match[4])] : void 0;
181
- };
182
- const left = parse(actual), right = parse(minimum);
183
- if (!left || !right)
184
- return false;
185
- for (let index = 0; index < 4; index++)
186
- if (left[index] !== right[index])
187
- return left[index] > right[index];
188
- return true;
189
- }
190
- var DEFAULT_UPDATE_MANIFEST_URL;
191
- var init_self_update_manifest = __esm({
192
- "apps/body/dist/self-update-manifest.js"() {
193
- "use strict";
194
- DEFAULT_UPDATE_MANIFEST_URL = "https://usebeeline.app/dl/manifest.json";
195
- }
196
- });
197
-
198
62
  // apps/body/dist/wait.js
199
63
  import { spawn } from "node:child_process";
200
64
  import { createHash } from "node:crypto";
@@ -414,9 +278,9 @@ async function tryLock(key, about = {}) {
414
278
  return {
415
279
  held: true,
416
280
  release: () => new Promise((done) => {
281
+ server.close(() => done());
417
282
  for (const peer of peers)
418
283
  peer.destroy();
419
- server.close(() => done());
420
284
  })
421
285
  };
422
286
  return new Promise((resolve17, reject) => {
@@ -650,7 +514,7 @@ async function downloadBytes(url, fetchImpl = fetch, options = {}) {
650
514
  const report = options.report ?? progress;
651
515
  let step = `network DNS/connect/headers ${url}`;
652
516
  try {
653
- const response = await ask({ url, fetch: fetchImpl });
517
+ const response = await ask({ url, fetch: fetchImpl }, options.request);
654
518
  if (!response.ok)
655
519
  throw new Error(`HTTP ${response.status}`);
656
520
  if (!response.body)
@@ -737,6 +601,152 @@ var init_lifecycle_test_guard = __esm({
737
601
  }
738
602
  });
739
603
 
604
+ // apps/body/dist/self-update-manifest.js
605
+ async function readChannelVersion(channel, fetchImpl, signal) {
606
+ if (channel !== "latest" && channel !== "next")
607
+ throw new Error(`invalid helper release channel: ${channel}`);
608
+ const raw = await downloadBytes(DIST_TAGS_URL, fetchImpl, {
609
+ request: { headers: { "Cache-Control": "no-cache" }, signal }
610
+ });
611
+ const tags = JSON.parse(Buffer.from(raw).toString("utf8"));
612
+ const version = tags?.[channel];
613
+ if (typeof version !== "string" || !/^\d+\.\d+\.\d+(?:-rc\.[1-9]\d*)?$/.test(version)) {
614
+ throw new Error(`usebeeline npm dist-tag ${channel} has no valid helper version`);
615
+ }
616
+ return `v${version}`;
617
+ }
618
+ async function readPublishedBundle(platform, { env = process.env, releaseChannel = env.BEELINE_UPDATE_RELEASE_CHANNEL || env.BEELINE_RELEASE_CHANNEL?.trim() || "latest", fetchImpl, signal } = {}) {
619
+ const override = env.BEELINE_UPDATE_MANIFEST_URL?.trim();
620
+ const version = override ? void 0 : await readChannelVersion(releaseChannel, fetchImpl, signal);
621
+ const url = override || `${RELEASES_URL}/${version}/manifest.json`;
622
+ const raw = await downloadBytes(url, fetchImpl, { request: { signal } });
623
+ return { url, bundle: parseUpdateBundle(Buffer.from(raw).toString("utf8"), platform, version) };
624
+ }
625
+ function parseUpdateBundle(raw, platform, expectedVersion) {
626
+ let parsed;
627
+ try {
628
+ parsed = JSON.parse(raw);
629
+ } catch (error) {
630
+ throw new Error(`update manifest is not valid JSON: ${error instanceof Error ? error.message : String(error)}`);
631
+ }
632
+ if (typeof parsed !== "object" || parsed === null) {
633
+ throw new Error("update manifest is not an object");
634
+ }
635
+ const manifest = parsed;
636
+ if (expectedVersion && manifest.version !== expectedVersion) {
637
+ throw new Error(`update manifest does not match npm version ${expectedVersion}`);
638
+ }
639
+ const bundles = manifest.bundles;
640
+ if (typeof bundles !== "object" || bundles === null) {
641
+ throw new Error("update manifest has no bundles table");
642
+ }
643
+ const entry = bundles[platform];
644
+ if (typeof entry !== "object" || entry === null) {
645
+ throw new Error(`update manifest has no bundle for platform ${platform}`);
646
+ }
647
+ const bundle = entry;
648
+ const file = typeof bundle.file === "string" ? bundle.file : "";
649
+ const sha256 = typeof bundle.sha256 === "string" ? bundle.sha256.toLowerCase() : "";
650
+ if (!file || !/^[a-z0-9][a-z0-9._-]*$/i.test(file)) {
651
+ throw new Error(`update manifest names an unusable bundle file: ${JSON.stringify(bundle.file)}`);
652
+ }
653
+ if (!/^[0-9a-f]{64}$/.test(sha256)) {
654
+ throw new Error(`update manifest carries no usable sha256 for ${platform}`);
655
+ }
656
+ const sourceCommit = typeof bundle.commit === "string" && bundle.commit ? bundle.commit : typeof manifest.sourceCommit === "string" ? manifest.sourceCommit : void 0;
657
+ const version = typeof bundle.version === "string" && bundle.version ? bundle.version : typeof manifest.version === "string" ? manifest.version : void 0;
658
+ return {
659
+ file,
660
+ sha256,
661
+ ...typeof bundle.bytes === "number" ? { bytes: bundle.bytes } : {},
662
+ ...sourceCommit ? { commit: sourceCommit } : {},
663
+ ...version ? { version } : {},
664
+ ...typeof bundle.node === "string" ? { node: bundle.node } : {}
665
+ };
666
+ }
667
+ function compareBundleIdentity(installed, published) {
668
+ if (installed?.version && published.version && installed.version !== published.version) {
669
+ const installedNewer = versionAtLeast(installed.version, published.version);
670
+ const publishedNewer = versionAtLeast(published.version, installed.version);
671
+ if (installedNewer && !publishedNewer)
672
+ return { kind: "current" };
673
+ if (publishedNewer && !installedNewer)
674
+ return { kind: "update-available", published };
675
+ }
676
+ if (installed?.commit && published.commit) {
677
+ if (installed.commit === published.commit)
678
+ return { kind: "current" };
679
+ return { kind: "update-available", published };
680
+ }
681
+ if (installed?.version && published.version) {
682
+ const ordering = compareVersions(installed.version, published.version);
683
+ if (ordering > 0)
684
+ return { kind: "current" };
685
+ if (ordering < 0)
686
+ return { kind: "update-available", published };
687
+ if (installed.commit && published.commit)
688
+ return { kind: "current" };
689
+ return { kind: "current" };
690
+ }
691
+ const missing = [
692
+ ...installed?.commit || installed?.version ? [] : ["installed identity"],
693
+ ...published.commit || published.version ? [] : ["published identity"]
694
+ ];
695
+ return {
696
+ kind: "indeterminate",
697
+ reason: `cannot compare: ${missing.join(" and ")} unknown`
698
+ };
699
+ }
700
+ function compareVersions(a, b) {
701
+ const parse = (value) => {
702
+ const parts = value.split(/[.+-]/).filter(Boolean);
703
+ if (parts.length === 0)
704
+ return void 0;
705
+ return parts.map((part) => /^\d+$/.test(part) ? Number(part) : part);
706
+ };
707
+ const left = parse(a);
708
+ const right = parse(b);
709
+ if (!left || !right)
710
+ return a === b ? 0 : a > b ? 1 : -1;
711
+ const length = Math.max(left.length, right.length);
712
+ for (let index = 0; index < length; index += 1) {
713
+ const l = left[index];
714
+ const r = right[index];
715
+ if (l === void 0)
716
+ return -1;
717
+ if (r === void 0)
718
+ return 1;
719
+ if (l === r)
720
+ continue;
721
+ if (typeof l === "number" && typeof r === "number")
722
+ return l > r ? 1 : -1;
723
+ return String(l) > String(r) ? 1 : -1;
724
+ }
725
+ return 0;
726
+ }
727
+ function versionAtLeast(actual, minimum) {
728
+ const parse = (value) => {
729
+ const match = /^v?(\d+)\.(\d+)\.(\d+)(?:-rc\.(\d+))?$/.exec(value);
730
+ return match ? [...match.slice(1, 4).map(Number), match[4] === void 0 ? Infinity : Number(match[4])] : void 0;
731
+ };
732
+ const left = parse(actual), right = parse(minimum);
733
+ if (!left || !right)
734
+ return false;
735
+ for (let index = 0; index < 4; index++)
736
+ if (left[index] !== right[index])
737
+ return left[index] > right[index];
738
+ return true;
739
+ }
740
+ var DIST_TAGS_URL, RELEASES_URL;
741
+ var init_self_update_manifest = __esm({
742
+ "apps/body/dist/self-update-manifest.js"() {
743
+ "use strict";
744
+ init_update_download();
745
+ DIST_TAGS_URL = "https://registry.npmjs.org/-/package/usebeeline/dist-tags";
746
+ RELEASES_URL = "https://downloads.usebeeline.app/dl/releases";
747
+ }
748
+ });
749
+
740
750
  // apps/body/dist/trusty-squire-storage.js
741
751
  import { homedir } from "node:os";
742
752
  import { isAbsolute, resolve as resolve2 } from "node:path";
@@ -1121,10 +1131,10 @@ __export(self_update_exports, {
1121
1131
  describeIdentity: () => describeIdentity,
1122
1132
  discoveredBeelineInstallLayout: () => discoveredBeelineInstallLayout,
1123
1133
  entrypointCandidates: () => entrypointCandidates,
1124
- fetchText: () => fetchText,
1125
1134
  forwarderScript: () => forwarderScript,
1126
1135
  fsyncDir: () => fsyncDir,
1127
1136
  hostPlatformKey: () => hostPlatformKey,
1137
+ installedReleaseChannel: () => installedReleaseChannel,
1128
1138
  nodeVersionAtLeast: () => nodeVersionAtLeast,
1129
1139
  normalizeLegacyBundleShape: () => normalizeLegacyBundleShape,
1130
1140
  pathKind: () => pathKind,
@@ -1142,6 +1152,7 @@ __export(self_update_exports, {
1142
1152
  runningReleaseId: () => runningReleaseId,
1143
1153
  sanitizeReleaseId: () => sanitizeReleaseId,
1144
1154
  stageRelease: () => stageRelease,
1155
+ updateCommandReleaseEnv: () => updateCommandReleaseEnv,
1145
1156
  updateStatePath: () => updateStatePath,
1146
1157
  writeUpdateState: () => writeUpdateState
1147
1158
  });
@@ -1270,6 +1281,29 @@ function nodeVersionAtLeast(version, minimum) {
1270
1281
  function updateStatePath(layout) {
1271
1282
  return join2(layout.releasesRoot, ".state", "update-state.json");
1272
1283
  }
1284
+ function releaseChannelPath(layout) {
1285
+ return join2(dirname3(updateStatePath(layout)), "release-channel");
1286
+ }
1287
+ async function installedReleaseChannel(layout, env = process.env) {
1288
+ const recorded = (await readFile2(releaseChannelPath(layout), "utf8").catch(() => "")).trim();
1289
+ if (recorded === "next" || recorded === "latest")
1290
+ return recorded;
1291
+ return env.BEELINE_RELEASE_CHANNEL?.trim() || "latest";
1292
+ }
1293
+ async function updateCommandReleaseEnv(layout, override, rememberChannel) {
1294
+ const explicit = process.env.BEELINE_RELEASE_CHANNEL?.trim();
1295
+ if (rememberChannel && (explicit === "next" || explicit === "latest")) {
1296
+ const path = releaseChannelPath(layout);
1297
+ await mkdir2(dirname3(path), { recursive: true });
1298
+ await replaceFile(path, `${explicit}
1299
+ `, 384);
1300
+ }
1301
+ return {
1302
+ ...process.env,
1303
+ BEELINE_UPDATE_RELEASE_CHANNEL: explicit || await installedReleaseChannel(layout),
1304
+ BEELINE_UPDATE_MANIFEST_URL: override ?? process.env.BEELINE_UPDATE_MANIFEST_URL
1305
+ };
1306
+ }
1273
1307
  async function readUpdateState(layout) {
1274
1308
  try {
1275
1309
  return JSON.parse(await readFile2(updateStatePath(layout), "utf8"));
@@ -1344,9 +1378,6 @@ function archiveUrlFor(manifestUrl, file) {
1344
1378
  return file;
1345
1379
  return `${withoutTrailingSlash.slice(0, index)}/${file}`;
1346
1380
  }
1347
- async function fetchText(url, fetchImpl) {
1348
- return Buffer.from(await downloadBytes(url, fetchImpl)).toString("utf8");
1349
- }
1350
1381
  function entrypointCandidates(bundleDir) {
1351
1382
  return [join2(bundleDir, BUNDLE_ENTRYPOINT), join2(bundleDir, "beeline-cli.mjs")];
1352
1383
  }
@@ -1519,8 +1550,12 @@ async function prepareLatestRelease(layout, options = {}) {
1519
1550
  ...options.signal ? { signal: options.signal } : {}
1520
1551
  });
1521
1552
  try {
1522
- const manifestUrl = options.manifest?.url ?? resolveManifestUrl(options.env ?? process.env);
1523
- const bundle = options.manifest?.bundle ?? parseUpdateManifest(await fetchText(manifestUrl, fetchImpl), hostPlatformKey()).bundle;
1553
+ const env = options.env ?? process.env;
1554
+ const { url, bundle } = options.manifest ?? await readPublishedBundle(hostPlatformKey(), {
1555
+ env,
1556
+ releaseChannel: env.BEELINE_UPDATE_RELEASE_CHANNEL || await installedReleaseChannel(layout, env),
1557
+ fetchImpl
1558
+ });
1524
1559
  options.signal?.throwIfAborted();
1525
1560
  const installed = await readInstalledBundleIdentity(layout);
1526
1561
  const active = await activeReleaseId(layout);
@@ -1532,7 +1567,7 @@ async function prepareLatestRelease(layout, options = {}) {
1532
1567
  options.logger?.(`already on ${installed?.version ?? active}; verifying content and repairing helper`);
1533
1568
  const holds = async (id) => Boolean(id) && (await readFile2(join2(layout.releasesRoot, id, ".stage-ok"), "utf8").catch(() => "")).trim() === bundle.sha256;
1534
1569
  const pending = (await readUpdateState(layout)).stagedReleaseId;
1535
- const releaseId = !options.force && await holds(pending) ? pending : !options.force && await holds(active) ? active : await stageRelease(layout, manifestUrl, bundle, {
1570
+ const releaseId = !options.force && await holds(pending) ? pending : !options.force && await holds(active) ? active : await stageRelease(layout, url, bundle, {
1536
1571
  fetchImpl,
1537
1572
  logger: options.logger,
1538
1573
  force: options.force,
@@ -1560,7 +1595,6 @@ var RELEASES_SEGMENT, STAGED_NODE_PATH_FILE, BUNDLE_ENTRYPOINT, PI_MCP_ADAPTER_E
1560
1595
  var init_self_update = __esm({
1561
1596
  "apps/body/dist/self-update.js"() {
1562
1597
  "use strict";
1563
- init_self_update_manifest();
1564
1598
  init_update_download();
1565
1599
  init_wait();
1566
1600
  init_lifecycle_test_guard();
@@ -4019,10 +4053,22 @@ var init_phone_guards_read_choice_card = __esm({
4019
4053
  }
4020
4054
  });
4021
4055
 
4056
+ // packages/api-contract/dist/chat-links.js
4057
+ var THREAD_NAME, HANDLE, TOKEN_PATTERN;
4058
+ var init_chat_links = __esm({
4059
+ "packages/api-contract/dist/chat-links.js"() {
4060
+ "use strict";
4061
+ THREAD_NAME = String.raw`[\p{L}\p{N}](?:[\p{L}\p{M}\p{N}_-]*[\p{L}\p{M}\p{N}_])?`;
4062
+ HANDLE = String.raw`[A-Za-z0-9](?:[A-Za-z0-9_-]*[A-Za-z0-9_])?`;
4063
+ TOKEN_PATTERN = new RegExp(String.raw`(?:↳(${THREAD_NAME})|¶(${HANDLE})-([1-9][0-9]{0,8}))(?![\p{L}\p{M}\p{N}_]|-[\p{L}\p{N}])`, "gu");
4064
+ }
4065
+ });
4066
+
4022
4067
  // packages/api-contract/dist/work-board.js
4023
4068
  var init_work_board = __esm({
4024
4069
  "packages/api-contract/dist/work-board.js"() {
4025
4070
  "use strict";
4071
+ init_chat_links();
4026
4072
  init_phone_guards();
4027
4073
  }
4028
4074
  });
@@ -4759,7 +4805,7 @@ var reviewRule, EXTERNAL_AGENT_RULES;
4759
4805
  var init_external_agent_rules = __esm({
4760
4806
  "packages/api-contract/dist/external-agent-rules.js"() {
4761
4807
  "use strict";
4762
- reviewRule = "As reviewer, read facets brief, pr and checks. Start your verdict with PASS or FAIL and include your findings. Use post once with the review wake\u2019s address and commandId. After posting PASS, call approve_merge on the exact head SHA with the address and headSha. The server wakes the implementer with the result. During review, send addressed messages only with reply. The server requests review; never tag the reviewer. Never review work you implemented or authored.";
4808
+ reviewRule = "As reviewer, read facets brief, pr and checks and include your findings in the verdict. To approve, call approve_merge on the exact head SHA with the review wake\u2019s address, commandId and verdict text. To request changes, use post once with the review wake\u2019s address and commandId. The server wakes the implementer with the result. The server requests review; never tag the reviewer. Never review work you implemented or authored.";
4763
4809
  EXTERNAL_AGENT_RULES = [
4764
4810
  {
4765
4811
  id: "data",
@@ -4822,17 +4868,6 @@ var init_mcp_muse_recipe = __esm({
4822
4868
  }
4823
4869
  });
4824
4870
 
4825
- // packages/api-contract/dist/chat-links.js
4826
- var THREAD_NAME, HANDLE, TOKEN_PATTERN;
4827
- var init_chat_links = __esm({
4828
- "packages/api-contract/dist/chat-links.js"() {
4829
- "use strict";
4830
- THREAD_NAME = String.raw`[\p{L}\p{N}](?:[\p{L}\p{M}\p{N}_-]*[\p{L}\p{M}\p{N}_])?`;
4831
- HANDLE = String.raw`[A-Za-z0-9](?:[A-Za-z0-9_-]*[A-Za-z0-9_])?`;
4832
- TOKEN_PATTERN = new RegExp(String.raw`(?:↳(${THREAD_NAME})|¶(${HANDLE})-([1-9][0-9]{0,8}))(?![\p{L}\p{M}\p{N}_]|-[\p{L}\p{N}])`, "gu");
4833
- }
4834
- });
4835
-
4836
4871
  // packages/api-contract/dist/phone.js
4837
4872
  var init_phone = __esm({
4838
4873
  "packages/api-contract/dist/phone.js"() {
@@ -27449,6 +27484,7 @@ async function main() {
27449
27484
  native: native2,
27450
27485
  installed: await readInstalledBundleIdentity(layout),
27451
27486
  activeRelease: await activeReleaseId(layout),
27487
+ releaseChannel: await installedReleaseChannel(layout),
27452
27488
  releaseSelection: await readUpdateState(layout),
27453
27489
  helper: helper ?? { state: "not responding" },
27454
27490
  agents
@@ -27456,16 +27492,17 @@ async function main() {
27456
27492
  return;
27457
27493
  }
27458
27494
  const index = args.indexOf("--manifest-url");
27459
- const url = index >= 0 ? args[index + 1] : resolveManifestUrl();
27460
- if (args.includes("--check")) {
27461
- const bundle = parseUpdateManifest(await fetchText(url, fetch), hostPlatformKey()).bundle;
27495
+ const checkOnly = args.includes("--check");
27496
+ const env = await updateCommandReleaseEnv(layout, index >= 0 ? args[index + 1] : void 0, command2 === "update" && !checkOnly);
27497
+ if (checkOnly) {
27498
+ const { bundle } = await readPublishedBundle(hostPlatformKey(), { env });
27462
27499
  console.log(compareBundleIdentity(await readInstalledBundleIdentity(layout), bundle));
27463
27500
  return;
27464
27501
  }
27465
27502
  let target;
27466
27503
  try {
27467
27504
  target = await prepareMachineRelease(layout, {
27468
- env: { ...process.env, BEELINE_UPDATE_MANIFEST_URL: url },
27505
+ env,
27469
27506
  force: args.includes("--force")
27470
27507
  });
27471
27508
  } catch (error) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "usebeeline",
3
- "version": "0.1.248-rc.2",
3
+ "version": "0.1.249-rc.3",
4
4
  "description": "Connect an AI coding agent to Beeline with one command.",
5
5
  "homepage": "https://usebeeline.app",
6
6
  "bugs": {