@madarco/agentbox 0.24.4 → 0.24.5

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.
Files changed (106) hide show
  1. package/CHANGELOG.md +11 -0
  2. package/dist/_cloud-attach-ESCPOKG5.js +0 -0
  3. package/dist/chunk-3MDYQROX.js +0 -0
  4. package/dist/chunk-4HPLS5HJ.js +0 -0
  5. package/dist/chunk-5JDOTQTM.js +0 -0
  6. package/dist/chunk-7DPDUZ7L.js +0 -0
  7. package/dist/chunk-CE3S7UDQ.js +0 -0
  8. package/dist/chunk-G3H2L3O2.js +0 -0
  9. package/dist/chunk-H6A4BQMG.js +0 -0
  10. package/dist/chunk-LJMGHFLZ.js +0 -0
  11. package/dist/chunk-OSPM4Q5V.js +0 -0
  12. package/dist/chunk-QHISF6O6.js +0 -0
  13. package/dist/chunk-RFRWS5CD.js +0 -0
  14. package/dist/chunk-WJFZJZIM.js +0 -0
  15. package/dist/cloud-poller-SUNA6ZQC-7M5LJHHE.js +0 -0
  16. package/dist/dist-2N3XHMBQ.js +0 -0
  17. package/dist/dist-3M53BF4E.js +0 -0
  18. package/dist/dist-FGXCG4JY.js +0 -0
  19. package/dist/dist-HPPHBZTO.js +0 -0
  20. package/dist/dist-NOUPH5E6.js +0 -0
  21. package/dist/dist-TRKHS6I7.js +0 -0
  22. package/dist/dist-VFPT5TDH.js +0 -0
  23. package/dist/index.js +96 -74
  24. package/dist/index.js.map +1 -1
  25. package/dist/prepared-state-BUO75YLZ-46W2PAHH.js +0 -0
  26. package/package.json +29 -28
  27. package/runtime/_shared/agentbox-checkpoint-cleanup +0 -0
  28. package/runtime/_shared/agentbox-dockerd-start +0 -0
  29. package/runtime/_shared/agentbox-open +0 -0
  30. package/runtime/_shared/agentbox-portless-trust +0 -0
  31. package/runtime/_shared/agentbox-vnc-start +0 -0
  32. package/runtime/_shared/ctl.cjs +0 -0
  33. package/runtime/_shared/gh-shim +0 -0
  34. package/runtime/_shared/git-shim +0 -0
  35. package/runtime/_shared/linear-shim +0 -0
  36. package/runtime/_shared/ntn-shim +0 -0
  37. package/runtime/digitalocean/agentbox-checkpoint-cleanup +0 -0
  38. package/runtime/digitalocean/agentbox-dockerd-start +0 -0
  39. package/runtime/digitalocean/agentbox-open +0 -0
  40. package/runtime/digitalocean/agentbox-portless-trust +0 -0
  41. package/runtime/digitalocean/agentbox-vnc-start +0 -0
  42. package/runtime/digitalocean/ctl.cjs +0 -0
  43. package/runtime/digitalocean/gh-shim +0 -0
  44. package/runtime/digitalocean/git-shim +0 -0
  45. package/runtime/digitalocean/linear-shim +0 -0
  46. package/runtime/digitalocean/ntn-shim +0 -0
  47. package/runtime/digitalocean/scripts/install-box.sh +0 -0
  48. package/runtime/docker/packages/ctl/dist/bin.cjs +0 -0
  49. package/runtime/docker/packages/sandbox-docker/scripts/agentbox-checkpoint-cleanup +0 -0
  50. package/runtime/docker/packages/sandbox-docker/scripts/agentbox-dockerd-start +0 -0
  51. package/runtime/docker/packages/sandbox-docker/scripts/agentbox-open +0 -0
  52. package/runtime/docker/packages/sandbox-docker/scripts/agentbox-portless-trust +0 -0
  53. package/runtime/docker/packages/sandbox-docker/scripts/agentbox-sshd-start +0 -0
  54. package/runtime/docker/packages/sandbox-docker/scripts/agentbox-vnc-start +0 -0
  55. package/runtime/docker/packages/sandbox-docker/scripts/chromium-resolver +0 -0
  56. package/runtime/docker/packages/sandbox-docker/scripts/gh-shim +0 -0
  57. package/runtime/docker/packages/sandbox-docker/scripts/git-shim +0 -0
  58. package/runtime/docker/packages/sandbox-docker/scripts/linear-shim +0 -0
  59. package/runtime/docker/packages/sandbox-docker/scripts/ntn-shim +0 -0
  60. package/runtime/e2b/agentbox-checkpoint-cleanup +0 -0
  61. package/runtime/e2b/agentbox-dockerd-start +0 -0
  62. package/runtime/e2b/agentbox-open +0 -0
  63. package/runtime/e2b/agentbox-vnc-start +0 -0
  64. package/runtime/e2b/ctl.cjs +0 -0
  65. package/runtime/e2b/gh-shim +0 -0
  66. package/runtime/e2b/git-shim +0 -0
  67. package/runtime/e2b/linear-shim +0 -0
  68. package/runtime/e2b/ntn-shim +0 -0
  69. package/runtime/e2b/scripts/build-template.sh +0 -0
  70. package/runtime/hetzner/agentbox-checkpoint-cleanup +0 -0
  71. package/runtime/hetzner/agentbox-dockerd-start +0 -0
  72. package/runtime/hetzner/agentbox-open +0 -0
  73. package/runtime/hetzner/agentbox-portless-trust +0 -0
  74. package/runtime/hetzner/agentbox-vnc-start +0 -0
  75. package/runtime/hetzner/ctl.cjs +0 -0
  76. package/runtime/hetzner/gh-shim +0 -0
  77. package/runtime/hetzner/git-shim +0 -0
  78. package/runtime/hetzner/linear-shim +0 -0
  79. package/runtime/hetzner/ntn-shim +0 -0
  80. package/runtime/hetzner/scripts/install-box.sh +0 -0
  81. package/runtime/hub/apps/hub/.next/BUILD_ID +1 -1
  82. package/runtime/hub/apps/hub/.next/build-manifest.json +3 -3
  83. package/runtime/hub/apps/hub/.next/server/app/_global-error.html +1 -1
  84. package/runtime/hub/apps/hub/.next/server/app/_global-error.rsc +1 -1
  85. package/runtime/hub/apps/hub/.next/server/app/_global-error.segments/__PAGE__.segment.rsc +1 -1
  86. package/runtime/hub/apps/hub/.next/server/app/_global-error.segments/_full.segment.rsc +1 -1
  87. package/runtime/hub/apps/hub/.next/server/app/_global-error.segments/_head.segment.rsc +1 -1
  88. package/runtime/hub/apps/hub/.next/server/app/_global-error.segments/_index.segment.rsc +1 -1
  89. package/runtime/hub/apps/hub/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -1
  90. package/runtime/hub/apps/hub/.next/server/middleware-build-manifest.js +3 -3
  91. package/runtime/hub/apps/hub/.next/server/pages/500.html +1 -1
  92. package/runtime/relay/bin.cjs +0 -0
  93. package/runtime/vercel/agentbox-checkpoint-cleanup +0 -0
  94. package/runtime/vercel/agentbox-dockerd-start +0 -0
  95. package/runtime/vercel/agentbox-open +0 -0
  96. package/runtime/vercel/agentbox-vnc-start +0 -0
  97. package/runtime/vercel/ctl.cjs +0 -0
  98. package/runtime/vercel/gh-shim +0 -0
  99. package/runtime/vercel/git-shim +0 -0
  100. package/runtime/vercel/linear-shim +0 -0
  101. package/runtime/vercel/ntn-shim +0 -0
  102. package/runtime/vercel/scripts/provision.sh +0 -0
  103. package/LICENSE +0 -21
  104. /package/runtime/hub/apps/hub/.next/static/{bwxNg9k-GQFyi2ouG8Aeh → 43_nml7FKErUxJXpspAhb}/_buildManifest.js +0 -0
  105. /package/runtime/hub/apps/hub/.next/static/{bwxNg9k-GQFyi2ouG8Aeh → 43_nml7FKErUxJXpspAhb}/_clientMiddlewareManifest.js +0 -0
  106. /package/runtime/hub/apps/hub/.next/static/{bwxNg9k-GQFyi2ouG8Aeh → 43_nml7FKErUxJXpspAhb}/_ssgManifest.js +0 -0
package/CHANGELOG.md CHANGED
@@ -9,6 +9,17 @@ Entries are generated from the commit history with `/release-notes` and then
9
9
  hand-reviewed — they describe what changed for someone using the `agentbox`
10
10
  CLI, not the raw commits.
11
11
 
12
+ ## [0.24.5] - 2026-07-12
13
+
14
+ ### Fixed
15
+
16
+ - Update checks no longer interrupt `create` / `claude` / `codex` and the other
17
+ box commands — they say nothing about updates at all, and a newer menu-bar app
18
+ is now a one-line note after a quiet command instead of a prompt.
19
+ - The menu-bar app no longer reports a phantom update when it is already current
20
+ (it was comparing an install stamp rather than the app's actual version, so an
21
+ app installed from the DMG always looked stale).
22
+
12
23
  ## [0.24.4] - 2026-07-12
13
24
 
14
25
  ### Added
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
package/dist/index.js CHANGED
@@ -376,8 +376,8 @@ import {
376
376
  } from "./chunk-WJFZJZIM.js";
377
377
 
378
378
  // src/version.ts
379
- var AGENTBOX_VERSION = true ? "0.24.4" : "0.0.0-dev";
380
- var AGENTBOX_COMMIT = true ? "a31f13870" : "dev";
379
+ var AGENTBOX_VERSION = true ? "0.24.5" : "0.0.0-dev";
380
+ var AGENTBOX_COMMIT = true ? "050a9c036" : "dev";
381
381
 
382
382
  // src/index.ts
383
383
  import { existsSync as _existsSync } from "fs";
@@ -1156,6 +1156,30 @@ import { tmpdir } from "os";
1156
1156
  import { join as join2 } from "path";
1157
1157
  import { setTimeout as delay } from "timers/promises";
1158
1158
 
1159
+ // src/lib/semver-lite.ts
1160
+ var TRIPLET = /^(\d+)\.(\d+)\.(\d+)$/;
1161
+ function parseTriplet(v) {
1162
+ const m = TRIPLET.exec(v.trim());
1163
+ if (!m) return null;
1164
+ return [Number(m[1]), Number(m[2]), Number(m[3])];
1165
+ }
1166
+ function compareSemver(a, b) {
1167
+ const pa = parseTriplet(a);
1168
+ const pb = parseTriplet(b);
1169
+ if (!pa || !pb) return null;
1170
+ for (let i = 0; i < 3; i++) {
1171
+ const ai = pa[i];
1172
+ const bi = pb[i];
1173
+ if (ai < bi) return -1;
1174
+ if (ai > bi) return 1;
1175
+ }
1176
+ return 0;
1177
+ }
1178
+ function isNewer(latest, current) {
1179
+ if (latest === void 0) return false;
1180
+ return compareSemver(latest, current) === 1;
1181
+ }
1182
+
1159
1183
  // src/lib/update-state.ts
1160
1184
  import { existsSync, mkdirSync, readFileSync, writeFileSync } from "fs";
1161
1185
  import { homedir } from "os";
@@ -1172,7 +1196,6 @@ function readUpdateState() {
1172
1196
  const state = { version: STATE_VERSION };
1173
1197
  if (typeof parsed.lastRunVersion === "string") state.lastRunVersion = parsed.lastRunVersion;
1174
1198
  if (typeof parsed.traySha === "string") state.traySha = parsed.traySha;
1175
- if (typeof parsed.trayDeclinedSha === "string") state.trayDeclinedSha = parsed.trayDeclinedSha;
1176
1199
  if (parsed.remoteCheck !== void 0 && typeof parsed.remoteCheck === "object" && typeof parsed.remoteCheck.checkedAt === "string") {
1177
1200
  state.remoteCheck = {
1178
1201
  checkedAt: parsed.remoteCheck.checkedAt,
@@ -1307,18 +1330,36 @@ function parseVersionManifest(body) {
1307
1330
  }
1308
1331
  function decideTrayUpdate(input) {
1309
1332
  if (!input.installed) return { update: false, reason: "not-installed" };
1333
+ const { installedVersion, latestVersion } = input;
1334
+ if (installedVersion !== void 0 && latestVersion !== void 0 && isReleaseVersion(installedVersion) && isReleaseVersion(latestVersion)) {
1335
+ return isNewer(latestVersion, installedVersion) ? { update: true, reason: "older-version" } : { update: false, reason: "up-to-date" };
1336
+ }
1310
1337
  if (input.latestSha === void 0) return { update: false, reason: "no-latest-sha" };
1311
1338
  if (input.stampedSha === void 0) return { update: true, reason: "no-stamp" };
1312
1339
  if (input.stampedSha !== input.latestSha) return { update: true, reason: "mismatch" };
1313
1340
  return { update: false, reason: "up-to-date" };
1314
1341
  }
1315
- function shouldPromptTrayUpdate(input) {
1316
- if (input.declinedSha !== void 0 && input.declinedSha === input.latestSha) return false;
1317
- return decideTrayUpdate({
1318
- installed: input.installed,
1319
- stampedSha: input.stampedSha,
1320
- latestSha: input.latestSha
1321
- }).update;
1342
+ function isReleaseVersion(v) {
1343
+ const core = v.split("-", 1)[0] ?? v;
1344
+ const parts = core.split(".");
1345
+ return parts.length === 3 && parts.every((p) => /^\d+$/.test(p)) && core !== "0.0.0";
1346
+ }
1347
+ async function readInstalledTrayVersion() {
1348
+ if (!trayInstalled()) return void 0;
1349
+ try {
1350
+ const { stdout } = await execa("plutil", [
1351
+ "-extract",
1352
+ "CFBundleShortVersionString",
1353
+ "raw",
1354
+ "-o",
1355
+ "-",
1356
+ join2(APP_PATH, "Contents", "Info.plist")
1357
+ ]);
1358
+ const v = stdout.trim();
1359
+ return v.length > 0 ? v : void 0;
1360
+ } catch {
1361
+ return void 0;
1362
+ }
1322
1363
  }
1323
1364
  async function trayRunning() {
1324
1365
  return await execa("pgrep", ["-x", APP_NAME]).catch(() => null) !== null;
@@ -18002,7 +18043,9 @@ async function maybeUpdateTray(say) {
18002
18043
  const decision = decideTrayUpdate({
18003
18044
  installed: true,
18004
18045
  stampedSha: state.traySha,
18005
- latestSha
18046
+ latestSha,
18047
+ installedVersion: await readInstalledTrayVersion(),
18048
+ latestVersion: state.remoteCheck?.trayLatestVersion
18006
18049
  });
18007
18050
  if (!decision.update) {
18008
18051
  say(
@@ -18109,30 +18152,6 @@ function detectExecutionMethod(input) {
18109
18152
  return "direct";
18110
18153
  }
18111
18154
 
18112
- // src/lib/semver-lite.ts
18113
- var TRIPLET = /^(\d+)\.(\d+)\.(\d+)$/;
18114
- function parseTriplet(v) {
18115
- const m = TRIPLET.exec(v.trim());
18116
- if (!m) return null;
18117
- return [Number(m[1]), Number(m[2]), Number(m[3])];
18118
- }
18119
- function compareSemver(a, b) {
18120
- const pa = parseTriplet(a);
18121
- const pb = parseTriplet(b);
18122
- if (!pa || !pb) return null;
18123
- for (let i = 0; i < 3; i++) {
18124
- const ai = pa[i];
18125
- const bi = pb[i];
18126
- if (ai < bi) return -1;
18127
- if (ai > bi) return 1;
18128
- }
18129
- return 0;
18130
- }
18131
- function isNewer(latest, current) {
18132
- if (latest === void 0) return false;
18133
- return compareSemver(latest, current) === 1;
18134
- }
18135
-
18136
18155
  // src/lib/update-check.ts
18137
18156
  var PKG = "@madarco/agentbox";
18138
18157
  var REGISTRY_URL = `https://registry.npmjs.org/${PKG}/latest`;
@@ -18203,6 +18222,12 @@ function maybeStartRemoteCheck() {
18203
18222
  };
18204
18223
  return run().catch(() => void 0);
18205
18224
  }
18225
+ function trayNudgeMessage(state, installedVersion) {
18226
+ const latest = state.remoteCheck?.trayLatestVersion;
18227
+ if (!latest || !installedVersion) return null;
18228
+ if (!isNewer(latest, installedVersion)) return null;
18229
+ return `a newer AgentBox app (${latest}, you have ${installedVersion}) is available \u2014 run \`agentbox install app\``;
18230
+ }
18206
18231
  function nudgeMessage(state, method, version = AGENTBOX_VERSION) {
18207
18232
  if (!nudgeEligible(method, version)) return null;
18208
18233
  const latest = state.remoteCheck?.npmLatest;
@@ -20071,6 +20096,27 @@ var FIRST_RUN_EXEMPT = /* @__PURE__ */ new Set([
20071
20096
  "drive",
20072
20097
  "screen"
20073
20098
  ]);
20099
+ var UPDATE_PROMPT_EXEMPT = /* @__PURE__ */ new Set([
20100
+ "create",
20101
+ "claude",
20102
+ "codex",
20103
+ "opencode",
20104
+ "shell",
20105
+ "sh",
20106
+ "attach",
20107
+ "exec",
20108
+ "run",
20109
+ "open",
20110
+ "fork",
20111
+ "url",
20112
+ "connect"
20113
+ ]);
20114
+ function isUpdatePromptEligible(args) {
20115
+ if (!isFirstRunHookEligible(args)) return false;
20116
+ const cmd = args[2];
20117
+ if (typeof cmd !== "string") return false;
20118
+ return !UPDATE_PROMPT_EXEMPT.has(cmd) && cmd !== "self-update";
20119
+ }
20074
20120
  function isFirstRunHookEligible(args) {
20075
20121
  if (!process.stdin.isTTY || !process.stdout.isTTY) return false;
20076
20122
  const rest = args.slice(2);
@@ -20098,7 +20144,7 @@ if (AGENTBOX_VERSION !== "0.0.0-dev") {
20098
20144
  const state = readUpdateState();
20099
20145
  if (state.lastRunVersion === void 0) {
20100
20146
  writeUpdateState({ lastRunVersion: AGENTBOX_VERSION });
20101
- } else if (state.lastRunVersion !== AGENTBOX_VERSION && isFirstRunHookEligible(argv) && argv[2] !== "self-update") {
20147
+ } else if (state.lastRunVersion !== AGENTBOX_VERSION && isUpdatePromptEligible(argv)) {
20102
20148
  versionPromptShown = true;
20103
20149
  try {
20104
20150
  const yes = await confirm({
@@ -20113,34 +20159,6 @@ if (AGENTBOX_VERSION !== "0.0.0-dev") {
20113
20159
  } catch (err) {
20114
20160
  process.stderr.write(
20115
20161
  `post-update refresh failed: ${err instanceof Error ? err.message : String(err)}
20116
- `
20117
- );
20118
- }
20119
- } else if (isFirstRunHookEligible(argv) && argv[2] !== "self-update" && shouldPromptTrayUpdate({
20120
- installed: trayInstalled(),
20121
- stampedSha: state.traySha,
20122
- latestSha: state.remoteCheck?.trayLatestSha,
20123
- declinedSha: state.trayDeclinedSha
20124
- })) {
20125
- const latestSha = state.remoteCheck?.trayLatestSha;
20126
- const latestVersion = state.remoteCheck?.trayLatestVersion;
20127
- versionPromptShown = true;
20128
- try {
20129
- const yes = await confirm({
20130
- message: latestVersion ? `the AgentBox menu-bar app has an update (${latestVersion}) \u2014 install it now?` : "the AgentBox menu-bar app has an update \u2014 install it now?",
20131
- initialValue: true
20132
- });
20133
- if (yes) {
20134
- await maybeUpdateTray((msg) => {
20135
- process.stdout.write(`${msg}
20136
- `);
20137
- });
20138
- } else {
20139
- writeUpdateState({ trayDeclinedSha: latestSha });
20140
- }
20141
- } catch (err) {
20142
- process.stderr.write(
20143
- `menu-bar app update failed: ${err instanceof Error ? err.message : String(err)}
20144
20162
  `
20145
20163
  );
20146
20164
  }
@@ -20151,17 +20169,21 @@ if (isFirstRunHookEligible(argv)) {
20151
20169
  }
20152
20170
  program.parseAsync(argv).then(
20153
20171
  async () => {
20154
- if (versionPromptShown || !isFirstRunHookEligible(argv)) return;
20155
- const msg = nudgeMessage(
20156
- readUpdateState(),
20157
- detectExecutionMethod({
20158
- userAgent: process.env.npm_config_user_agent,
20159
- argv1: process.argv[1]
20160
- })
20161
- );
20162
- if (msg !== null && await updateCheckEnabled()) {
20172
+ if (versionPromptShown || !isUpdatePromptEligible(argv)) return;
20173
+ const state = readUpdateState();
20174
+ const lines = [
20175
+ nudgeMessage(
20176
+ state,
20177
+ detectExecutionMethod({
20178
+ userAgent: process.env.npm_config_user_agent,
20179
+ argv1: process.argv[1]
20180
+ })
20181
+ ),
20182
+ trayNudgeMessage(state, await readInstalledTrayVersion())
20183
+ ].filter((l) => l !== null);
20184
+ if (lines.length > 0 && await updateCheckEnabled()) {
20163
20185
  process.stderr.write(`
20164
- ${msg}
20186
+ ${lines.join("\n")}
20165
20187
  `);
20166
20188
  }
20167
20189
  },