@madarco/agentbox 0.24.5 → 0.24.6

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
@@ -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.6] - 2026-07-12
13
+
14
+ ### Fixed
15
+
16
+ - `self-update` no longer deletes the box image. It's content-addressed, so an
17
+ update that doesn't change the build context now costs nothing — and when the
18
+ context *has* changed, `doctor` and the app both flag it as stale (fix with
19
+ `agentbox prepare --provider docker`) instead of it surfacing at create.
20
+ - `agentbox install` no longer offers to install the menu-bar app when it's
21
+ already installed; it offers an update only when one is actually available.
22
+
12
23
  ## [0.24.5] - 2026-07-12
13
24
 
14
25
  ### Fixed
package/dist/index.js CHANGED
@@ -221,7 +221,6 @@ import {
221
221
  registerBoxWithRelay,
222
222
  rehydrateRelayRegistry,
223
223
  removeCheckpoint,
224
- removeImage,
225
224
  renderPortsTable,
226
225
  renderStatusTable,
227
226
  renderTaskTable,
@@ -321,6 +320,7 @@ import {
321
320
  ensureCloudSshAlias,
322
321
  ensureImage,
323
322
  errSummary,
323
+ evaluateDockerBaseFreshness,
324
324
  firstLine,
325
325
  generateBoxId,
326
326
  hasUnmanagedHostConflict,
@@ -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.5" : "0.0.0-dev";
380
- var AGENTBOX_COMMIT = true ? "050a9c036" : "dev";
379
+ var AGENTBOX_VERSION = true ? "0.24.6" : "0.0.0-dev";
380
+ var AGENTBOX_COMMIT = true ? "59e7ce5e4" : "dev";
381
381
 
382
382
  // src/index.ts
383
383
  import { existsSync as _existsSync } from "fs";
@@ -3879,7 +3879,10 @@ async function evaluateCheckpoint(provider, projectRoot, ref) {
3879
3879
  return evaluateCloudCheckpoint(provider, projectRoot, ref);
3880
3880
  }
3881
3881
  async function evaluateBaseFreshness(provider, claudeInstall) {
3882
- if (provider === "docker") return { state: "fresh" };
3882
+ if (provider === "docker") {
3883
+ const { evaluateDockerBaseFreshness: evaluateDockerBaseFreshness2 } = await import("./dist-NOUPH5E6.js");
3884
+ return await evaluateDockerBaseFreshness2({ claudeInstall });
3885
+ }
3883
3886
  const stored = currentCloudBaseFingerprint(provider);
3884
3887
  if (!stored) return { state: "unprepared" };
3885
3888
  const current = await currentCloudBaseFingerprintLive(provider, claudeInstall).catch(() => void 0);
@@ -13353,7 +13356,6 @@ function resolveClaudeInstall() {
13353
13356
  return claudeInstallOnce;
13354
13357
  }
13355
13358
  async function baseFreshnessRow(name) {
13356
- if (name === "docker") return null;
13357
13359
  const status = await evaluateBaseFreshness(name, await resolveClaudeInstall()).catch(() => null);
13358
13360
  if (!status) return null;
13359
13361
  switch (status.state) {
@@ -14477,16 +14479,30 @@ pass \`agentbox install --skills-only --force\` to overwrite`
14477
14479
  const providerGroup = await runProviderChecks(providerName);
14478
14480
  process.stdout.write(" " + formatCompact([sysGroup, providerGroup]) + "\n");
14479
14481
  if (process.platform === "darwin") {
14480
- const wantTray = opts.yes ? true : await confirm({ message: "Install the AgentBox menu-bar app?", initialValue: true });
14481
- if (wantTray === true) {
14482
- const sp2 = (0, prompt_exports.spinner)();
14483
- sp2.start("Downloading menu-bar app");
14484
- try {
14485
- const res = await installTray({ quiet: true });
14486
- sp2.stop(res.ran ? "Menu-bar app: installed" : `Menu-bar app: skipped (${res.reason ?? ""})`);
14487
- } catch (err) {
14488
- sp2.stop("Menu-bar app: failed");
14489
- prompt_exports.log.warn(err instanceof Error ? err.message : String(err));
14482
+ const installedVersion = trayInstalled() ? await readInstalledTrayVersion() : void 0;
14483
+ const latestVersion = trayInstalled() ? readUpdateState().remoteCheck?.trayLatestVersion ?? await fetchTrayLatestVersion() : void 0;
14484
+ const behind = installedVersion !== void 0 && latestVersion !== void 0 && isNewer(latestVersion, installedVersion);
14485
+ let action = "install";
14486
+ if (trayInstalled()) action = behind ? "update" : "none";
14487
+ if (action === "none") {
14488
+ prompt_exports.log.info(
14489
+ `Menu-bar app: already installed${installedVersion ? ` (${installedVersion})` : ""}`
14490
+ );
14491
+ } else {
14492
+ const message = action === "update" ? `Update the AgentBox menu-bar app (${installedVersion ?? "?"} \u2192 ${latestVersion ?? "?"})?` : "Install the AgentBox menu-bar app?";
14493
+ const wantTray = opts.yes ? true : await confirm({ message, initialValue: true });
14494
+ if (wantTray === true) {
14495
+ const sp2 = (0, prompt_exports.spinner)();
14496
+ sp2.start(action === "update" ? "Updating menu-bar app" : "Downloading menu-bar app");
14497
+ try {
14498
+ const res = await installTray({ quiet: true });
14499
+ sp2.stop(
14500
+ res.ran ? `Menu-bar app: ${action === "update" ? "updated" : "installed"}` : `Menu-bar app: skipped (${res.reason ?? ""})`
14501
+ );
14502
+ } catch (err) {
14503
+ sp2.stop(`Menu-bar app: failed`);
14504
+ prompt_exports.log.warn(err instanceof Error ? err.message : String(err));
14505
+ }
14490
14506
  }
14491
14507
  }
14492
14508
  }
@@ -18081,12 +18097,12 @@ async function runPostUpdateRefresh(opts = {}) {
18081
18097
  }
18082
18098
  }
18083
18099
  try {
18084
- const removed = await removeImage(DEFAULT_BOX_IMAGE);
18100
+ const freshness = await evaluateDockerBaseFreshness();
18085
18101
  say(
18086
- removed ? `removed image ${DEFAULT_BOX_IMAGE} (rebuilds on next create/claude)` : `image ${DEFAULT_BOX_IMAGE} not present (nothing to remove)`
18102
+ freshness.state === "fresh" ? `box image ${DEFAULT_BOX_IMAGE} already current (build context unchanged)` : freshness.state === "stale" ? `box image ${DEFAULT_BOX_IMAGE}: build context changed \u2014 rebuilds on next create` : freshness.state === "unprepared" ? `box image ${DEFAULT_BOX_IMAGE} not present \u2014 pulled on next create` : `box image ${DEFAULT_BOX_IMAGE}: freshness unknown \u2014 left alone`
18087
18103
  );
18088
18104
  } catch (err) {
18089
- warn("box image removal", err);
18105
+ warn("box image check", err);
18090
18106
  }
18091
18107
  try {
18092
18108
  const hub = await getHubStatus();
@@ -19789,7 +19805,7 @@ async function reportLatest() {
19789
19805
  }
19790
19806
  }
19791
19807
  var updateCommand = new Command63("self-update").description(
19792
- "Update agentbox: self-update via npm/pnpm (unless run via npx), refresh the host skills, wipe the box image so it rebuilds, reload the relay, and update the menu-bar app"
19808
+ "Update agentbox: self-update via npm/pnpm (unless run via npx), refresh the host skills, re-check the box image (rebuilt on the next create only if its build context changed), reload the relay/hub, and update the menu-bar app"
19793
19809
  ).option("-y, --yes", "skip the confirmation prompt").option("--dry-run", "show what would happen, don't change anything").option("--skip-self", "skip the package self-update; only refresh the skills + image + relay + app").option("--skip-skills", "skip refreshing the host skill files in ~/.claude, ~/.codex, ~/.config/opencode").action(async (opts) => {
19794
19810
  try {
19795
19811
  const method = detectExecutionMethod({