@madarco/agentbox 0.24.0 → 0.24.1
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 +20 -0
- package/dist/index.js +81 -10
- package/dist/index.js.map +1 -1
- package/package.json +6 -6
- package/runtime/hub/apps/hub/.next/BUILD_ID +1 -1
- package/runtime/hub/apps/hub/.next/build-manifest.json +3 -3
- package/runtime/hub/apps/hub/.next/server/app/_global-error.html +1 -1
- package/runtime/hub/apps/hub/.next/server/app/_global-error.rsc +1 -1
- package/runtime/hub/apps/hub/.next/server/app/_global-error.segments/__PAGE__.segment.rsc +1 -1
- package/runtime/hub/apps/hub/.next/server/app/_global-error.segments/_full.segment.rsc +1 -1
- package/runtime/hub/apps/hub/.next/server/app/_global-error.segments/_head.segment.rsc +1 -1
- package/runtime/hub/apps/hub/.next/server/app/_global-error.segments/_index.segment.rsc +1 -1
- package/runtime/hub/apps/hub/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -1
- package/runtime/hub/apps/hub/.next/server/middleware-build-manifest.js +3 -3
- package/runtime/hub/apps/hub/.next/server/pages/500.html +1 -1
- /package/runtime/hub/apps/hub/.next/static/{XtIjHGqvY4mQsOY2-m1Jy → 3tBexekuTKIr_6nriQjKE}/_buildManifest.js +0 -0
- /package/runtime/hub/apps/hub/.next/static/{XtIjHGqvY4mQsOY2-m1Jy → 3tBexekuTKIr_6nriQjKE}/_clientMiddlewareManifest.js +0 -0
- /package/runtime/hub/apps/hub/.next/static/{XtIjHGqvY4mQsOY2-m1Jy → 3tBexekuTKIr_6nriQjKE}/_ssgManifest.js +0 -0
package/CHANGELOG.md
CHANGED
|
@@ -9,6 +9,26 @@ 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.1] - 2026-07-12
|
|
13
|
+
|
|
14
|
+
### Fixed
|
|
15
|
+
|
|
16
|
+
- **Menu-bar app updates were never offered.** The app is released separately from
|
|
17
|
+
the CLI, so an app-only release bumps no CLI version — and the post-update
|
|
18
|
+
prompt only fired on a CLI version change. A new app build could sit published
|
|
19
|
+
and unnoticed indefinitely, and you had to know to run `agentbox install app`
|
|
20
|
+
yourself. An interactive command now offers to install a newer app build even
|
|
21
|
+
when the CLI itself is unchanged, reading the existing daily check (no extra
|
|
22
|
+
network on the command path). Answering no remembers that build, so you are
|
|
23
|
+
asked once, not on every command — and only the app is reinstalled, without
|
|
24
|
+
touching the box image or the relay.
|
|
25
|
+
- Menu-bar app **0.1.10** — "Check for Updates…" now reports the app as well as
|
|
26
|
+
the CLI (it only ever compared the CLI, so it could report "up to date" while
|
|
27
|
+
the app itself was stale), and offers `agentbox install app` when only the app
|
|
28
|
+
is behind. Also fixes the DigitalOcean provider settings, which sent the API
|
|
29
|
+
token under the wrong key and always failed with "token is required". Update
|
|
30
|
+
with `agentbox install app` (or accept the new prompt).
|
|
31
|
+
|
|
12
32
|
## [0.24.0] - 2026-07-12
|
|
13
33
|
|
|
14
34
|
### Added
|
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.
|
|
380
|
-
var AGENTBOX_COMMIT = true ? "
|
|
379
|
+
var AGENTBOX_VERSION = true ? "0.24.1" : "0.0.0-dev";
|
|
380
|
+
var AGENTBOX_COMMIT = true ? "6633bb4ce" : "dev";
|
|
381
381
|
|
|
382
382
|
// src/index.ts
|
|
383
383
|
import { existsSync as _existsSync } from "fs";
|
|
@@ -1172,11 +1172,13 @@ function readUpdateState() {
|
|
|
1172
1172
|
const state = { version: STATE_VERSION };
|
|
1173
1173
|
if (typeof parsed.lastRunVersion === "string") state.lastRunVersion = parsed.lastRunVersion;
|
|
1174
1174
|
if (typeof parsed.traySha === "string") state.traySha = parsed.traySha;
|
|
1175
|
+
if (typeof parsed.trayDeclinedSha === "string") state.trayDeclinedSha = parsed.trayDeclinedSha;
|
|
1175
1176
|
if (parsed.remoteCheck !== void 0 && typeof parsed.remoteCheck === "object" && typeof parsed.remoteCheck.checkedAt === "string") {
|
|
1176
1177
|
state.remoteCheck = {
|
|
1177
1178
|
checkedAt: parsed.remoteCheck.checkedAt,
|
|
1178
1179
|
...typeof parsed.remoteCheck.npmLatest === "string" ? { npmLatest: parsed.remoteCheck.npmLatest } : {},
|
|
1179
|
-
...typeof parsed.remoteCheck.trayLatestSha === "string" ? { trayLatestSha: parsed.remoteCheck.trayLatestSha } : {}
|
|
1180
|
+
...typeof parsed.remoteCheck.trayLatestSha === "string" ? { trayLatestSha: parsed.remoteCheck.trayLatestSha } : {},
|
|
1181
|
+
...typeof parsed.remoteCheck.trayLatestVersion === "string" ? { trayLatestVersion: parsed.remoteCheck.trayLatestVersion } : {}
|
|
1180
1182
|
};
|
|
1181
1183
|
}
|
|
1182
1184
|
return state;
|
|
@@ -1282,6 +1284,27 @@ function parseSidecarSha(body) {
|
|
|
1282
1284
|
const first = body.trim().split(/\s+/)[0]?.toLowerCase();
|
|
1283
1285
|
return first && /^[0-9a-f]{64}$/.test(first) ? first : void 0;
|
|
1284
1286
|
}
|
|
1287
|
+
async function fetchTrayLatestVersion(tag2 = DEFAULT_TAG) {
|
|
1288
|
+
try {
|
|
1289
|
+
const { stdout } = await execa("curl", [
|
|
1290
|
+
"-fsSL",
|
|
1291
|
+
"--max-time",
|
|
1292
|
+
"5",
|
|
1293
|
+
`${RELEASE_BASE}/${tag2}/version.json`
|
|
1294
|
+
]);
|
|
1295
|
+
return parseVersionManifest(stdout);
|
|
1296
|
+
} catch {
|
|
1297
|
+
return void 0;
|
|
1298
|
+
}
|
|
1299
|
+
}
|
|
1300
|
+
function parseVersionManifest(body) {
|
|
1301
|
+
try {
|
|
1302
|
+
const parsed = JSON.parse(body);
|
|
1303
|
+
return typeof parsed.version === "string" && parsed.version !== "" ? parsed.version : void 0;
|
|
1304
|
+
} catch {
|
|
1305
|
+
return void 0;
|
|
1306
|
+
}
|
|
1307
|
+
}
|
|
1285
1308
|
function decideTrayUpdate(input) {
|
|
1286
1309
|
if (!input.installed) return { update: false, reason: "not-installed" };
|
|
1287
1310
|
if (input.latestSha === void 0) return { update: false, reason: "no-latest-sha" };
|
|
@@ -1289,6 +1312,14 @@ function decideTrayUpdate(input) {
|
|
|
1289
1312
|
if (input.stampedSha !== input.latestSha) return { update: true, reason: "mismatch" };
|
|
1290
1313
|
return { update: false, reason: "up-to-date" };
|
|
1291
1314
|
}
|
|
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;
|
|
1322
|
+
}
|
|
1292
1323
|
async function trayRunning() {
|
|
1293
1324
|
return await execa("pgrep", ["-x", APP_NAME]).catch(() => null) !== null;
|
|
1294
1325
|
}
|
|
@@ -18119,6 +18150,17 @@ async function fetchNpmLatest() {
|
|
|
18119
18150
|
return void 0;
|
|
18120
18151
|
}
|
|
18121
18152
|
}
|
|
18153
|
+
function mergeRemoteCheck(fetched, prev) {
|
|
18154
|
+
const npmLatest = fetched.npmLatest ?? prev?.npmLatest;
|
|
18155
|
+
const trayLatestSha = fetched.trayLatestSha ?? prev?.trayLatestSha;
|
|
18156
|
+
const shaMoved = fetched.trayLatestSha !== void 0 && fetched.trayLatestSha !== prev?.trayLatestSha;
|
|
18157
|
+
const trayLatestVersion = fetched.trayLatestVersion ?? (shaMoved ? void 0 : prev?.trayLatestVersion);
|
|
18158
|
+
return {
|
|
18159
|
+
...npmLatest !== void 0 ? { npmLatest } : {},
|
|
18160
|
+
...trayLatestSha !== void 0 ? { trayLatestSha } : {},
|
|
18161
|
+
...trayLatestVersion !== void 0 ? { trayLatestVersion } : {}
|
|
18162
|
+
};
|
|
18163
|
+
}
|
|
18122
18164
|
function maybeStartRemoteCheck() {
|
|
18123
18165
|
const state = readUpdateState();
|
|
18124
18166
|
if (remoteCheckFresh(state)) return null;
|
|
@@ -18129,20 +18171,21 @@ function maybeStartRemoteCheck() {
|
|
|
18129
18171
|
const run = async () => {
|
|
18130
18172
|
let npmLatest;
|
|
18131
18173
|
let trayLatestSha;
|
|
18174
|
+
let trayLatestVersion;
|
|
18132
18175
|
if (await updateCheckEnabled()) {
|
|
18133
|
-
[npmLatest, trayLatestSha] = await Promise.all([
|
|
18176
|
+
[npmLatest, trayLatestSha, trayLatestVersion] = await Promise.all([
|
|
18134
18177
|
nudgeEligible(method, AGENTBOX_VERSION) ? fetchNpmLatest() : Promise.resolve(void 0),
|
|
18135
|
-
trayInstalled() ? fetchTraySidecarSha() : Promise.resolve(void 0)
|
|
18178
|
+
trayInstalled() ? fetchTraySidecarSha() : Promise.resolve(void 0),
|
|
18179
|
+
trayInstalled() ? fetchTrayLatestVersion() : Promise.resolve(void 0)
|
|
18136
18180
|
]);
|
|
18137
18181
|
}
|
|
18138
|
-
const prev = readUpdateState().remoteCheck;
|
|
18139
|
-
npmLatest ??= prev?.npmLatest;
|
|
18140
|
-
trayLatestSha ??= prev?.trayLatestSha;
|
|
18141
18182
|
writeUpdateState({
|
|
18142
18183
|
remoteCheck: {
|
|
18143
18184
|
checkedAt: (/* @__PURE__ */ new Date()).toISOString(),
|
|
18144
|
-
...
|
|
18145
|
-
|
|
18185
|
+
...mergeRemoteCheck(
|
|
18186
|
+
{ npmLatest, trayLatestSha, trayLatestVersion },
|
|
18187
|
+
readUpdateState().remoteCheck
|
|
18188
|
+
)
|
|
18146
18189
|
}
|
|
18147
18190
|
});
|
|
18148
18191
|
};
|
|
@@ -20058,6 +20101,34 @@ if (AGENTBOX_VERSION !== "0.0.0-dev") {
|
|
|
20058
20101
|
} catch (err) {
|
|
20059
20102
|
process.stderr.write(
|
|
20060
20103
|
`post-update refresh failed: ${err instanceof Error ? err.message : String(err)}
|
|
20104
|
+
`
|
|
20105
|
+
);
|
|
20106
|
+
}
|
|
20107
|
+
} else if (isFirstRunHookEligible(argv) && argv[2] !== "self-update" && shouldPromptTrayUpdate({
|
|
20108
|
+
installed: trayInstalled(),
|
|
20109
|
+
stampedSha: state.traySha,
|
|
20110
|
+
latestSha: state.remoteCheck?.trayLatestSha,
|
|
20111
|
+
declinedSha: state.trayDeclinedSha
|
|
20112
|
+
})) {
|
|
20113
|
+
const latestSha = state.remoteCheck?.trayLatestSha;
|
|
20114
|
+
const latestVersion = state.remoteCheck?.trayLatestVersion;
|
|
20115
|
+
versionPromptShown = true;
|
|
20116
|
+
try {
|
|
20117
|
+
const yes = await confirm({
|
|
20118
|
+
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?",
|
|
20119
|
+
initialValue: true
|
|
20120
|
+
});
|
|
20121
|
+
if (yes) {
|
|
20122
|
+
await maybeUpdateTray((msg) => {
|
|
20123
|
+
process.stdout.write(`${msg}
|
|
20124
|
+
`);
|
|
20125
|
+
});
|
|
20126
|
+
} else {
|
|
20127
|
+
writeUpdateState({ trayDeclinedSha: latestSha });
|
|
20128
|
+
}
|
|
20129
|
+
} catch (err) {
|
|
20130
|
+
process.stderr.write(
|
|
20131
|
+
`menu-bar app update failed: ${err instanceof Error ? err.message : String(err)}
|
|
20061
20132
|
`
|
|
20062
20133
|
);
|
|
20063
20134
|
}
|