@liberseek/boft-cli-win32-arm64 0.7.7 → 0.7.8
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 +1 -1
- package/app/codexhost-distribution.json +1 -1
- package/app/console-server.mjs +16 -8
- package/app/console-web.js +141 -112
- package/app/desktop-controller.mjs +16 -2
- package/app/host-runtime.mjs +17 -8
- package/app/plugins/antigravity/plugin.mjs +5 -2
- package/app/plugins/claude-code/plugin.mjs +6 -2
- package/app/plugins/codebuddy/plugin.mjs +6 -2
- package/app/plugins/cursor-cli/plugin.mjs +5 -2
- package/app/plugins/deepseek-harness/plugin.mjs +6 -2
- package/app/plugins/grok/plugin.mjs +5 -2
- package/app/plugins/hermes/plugin.mjs +70 -10
- package/app/plugins/kimi-code/plugin.mjs +9 -3
- package/app/plugins/kiro-cli/plugin.mjs +16 -13
- package/app/plugins/muse/plugin.mjs +5 -2
- package/app/plugins/omp/plugin.mjs +34 -8
- package/app/plugins/opencode/plugin.mjs +9 -3
- package/app/plugins/pi/plugin.mjs +5 -2
- package/app/plugins/qoder/plugin.mjs +36 -3
- package/app/plugins/qoder-cn/plugin.mjs +36 -3
- package/app/plugins/workbuddy/plugin.mjs +5 -2
- package/app/renderer-extension.js +276 -193
- package/bin/boft.exe +0 -0
- package/libexec/boft-node-repl.exe +0 -0
- package/libexec/boft-shim.exe +0 -0
- package/libexec/boft-updater.exe +0 -0
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -7,7 +7,7 @@ BOFT CLI runs Pi and other external harnesses inside Codex Desktop.
|
|
|
7
7
|
## Install
|
|
8
8
|
|
|
9
9
|
```bash
|
|
10
|
-
npm install -g @liberseek/boft-cli@0.7.
|
|
10
|
+
npm install -g @liberseek/boft-cli@0.7.8
|
|
11
11
|
```
|
|
12
12
|
|
|
13
13
|
Do not install this package directly. npm selects it through the optional dependencies of `@liberseek/boft-cli`.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"schemaVersion":1,"version":"0.7.
|
|
1
|
+
{"schemaVersion":1,"version":"0.7.8","distribution":"npm","target":"windows-arm64"}
|
package/app/console-server.mjs
CHANGED
|
@@ -15307,7 +15307,10 @@ var harnessInstallationStateSchema = external_exports.object({
|
|
|
15307
15307
|
latestVersion: external_exports.string().min(1).max(128),
|
|
15308
15308
|
updateAvailable: external_exports.boolean(),
|
|
15309
15309
|
canUpdate: external_exports.boolean(),
|
|
15310
|
-
|
|
15310
|
+
// Adapter-owned diagnostic text; UI uses messageCode rather than displaying it verbatim.
|
|
15311
|
+
message: external_exports.string().max(2048).optional(),
|
|
15312
|
+
messageCode: external_exports.string().min(1).max(128).optional(),
|
|
15313
|
+
latestVersionKind: external_exports.enum(["unknown", "tracking-branch"]).optional()
|
|
15311
15314
|
}).strict();
|
|
15312
15315
|
|
|
15313
15316
|
// packages/shared-contracts/dist/codex-accounts.js
|
|
@@ -15597,7 +15600,7 @@ var updateStatusSchema = external_exports.strictObject({
|
|
|
15597
15600
|
}
|
|
15598
15601
|
});
|
|
15599
15602
|
var updateEmptyParamsSchema = external_exports.strictObject({});
|
|
15600
|
-
var githubReleaseNotesUrlSchema = external_exports.string().max(300).regex(/^https:\/\/github\.com\/LiberSeek\/BOFT-CLI\/releases\/tag\/v[0-9A-Za-z.+-]+$/u, "release notes URL must identify a codexhost GitHub Release");
|
|
15603
|
+
var githubReleaseNotesUrlSchema = external_exports.string().max(300).regex(/^https:\/\/github\.com\/(LiberSeek|LIBERSEEK)\/BOFT-CLI\/releases\/tag\/v[0-9A-Za-z.+-]+$/u, "release notes URL must identify a codexhost GitHub Release");
|
|
15601
15604
|
var updateCheckResultSchema = external_exports.strictObject({
|
|
15602
15605
|
currentVersion: updateSemanticVersionSchema,
|
|
15603
15606
|
installation: updateInstallationSchema.nullable(),
|
|
@@ -16238,8 +16241,14 @@ function defaultUpdateStateDirectory(platform = process.platform, environment =
|
|
|
16238
16241
|
// packages/update-manager/dist/github-release.js
|
|
16239
16242
|
var CODEXHOST_LATEST_RELEASE_URL = "https://api.github.com/repos/LiberSeek/BOFT-CLI/releases/latest";
|
|
16240
16243
|
var SHA256_DIGEST_PATTERN = /^sha256:([0-9a-f]{64})$/u;
|
|
16241
|
-
var RELEASE_NOTES_URL_PATTERN = /^https:\/\/github\.com\/LiberSeek\/BOFT-CLI\/releases\/tag\/(v[0-9A-Za-z.+-]+)$/u;
|
|
16242
|
-
var
|
|
16244
|
+
var RELEASE_NOTES_URL_PATTERN = /^https:\/\/github\.com\/(LiberSeek|LIBERSEEK)\/BOFT-CLI\/releases\/tag\/(v[0-9A-Za-z.+-]+)$/u;
|
|
16245
|
+
var DOWNLOAD_URL_PREFIXES = [
|
|
16246
|
+
"https://github.com/LiberSeek/BOFT-CLI/releases/download/",
|
|
16247
|
+
"https://github.com/LIBERSEEK/BOFT-CLI/releases/download/"
|
|
16248
|
+
];
|
|
16249
|
+
function isBoftReleaseDownloadUrl(url2, version2) {
|
|
16250
|
+
return DOWNLOAD_URL_PREFIXES.some((prefix) => url2.startsWith(version2 === void 0 ? prefix : `${prefix}v${version2}/`));
|
|
16251
|
+
}
|
|
16243
16252
|
function record2(value, label) {
|
|
16244
16253
|
if (typeof value !== "object" || value === null || Array.isArray(value)) {
|
|
16245
16254
|
throw new Error(`${label} must be an object`);
|
|
@@ -16248,7 +16257,7 @@ function record2(value, label) {
|
|
|
16248
16257
|
}
|
|
16249
16258
|
function releaseAsset(value) {
|
|
16250
16259
|
const asset = record2(value, "GitHub Release asset");
|
|
16251
|
-
if (typeof asset.name !== "string" || asset.name.length === 0 || asset.name.length > 160 || !Number.isSafeInteger(asset.size) || asset.size <= 0 || asset.size > 2 * 1024 * 1024 * 1024 || asset.digest != null && typeof asset.digest !== "string" || typeof asset.browser_download_url !== "string" || !asset.browser_download_url
|
|
16260
|
+
if (typeof asset.name !== "string" || asset.name.length === 0 || asset.name.length > 160 || !Number.isSafeInteger(asset.size) || asset.size <= 0 || asset.size > 2 * 1024 * 1024 * 1024 || asset.digest != null && typeof asset.digest !== "string" || typeof asset.browser_download_url !== "string" || !isBoftReleaseDownloadUrl(asset.browser_download_url)) {
|
|
16252
16261
|
throw new Error("GitHub Release asset is invalid");
|
|
16253
16262
|
}
|
|
16254
16263
|
const url2 = new URL(asset.browser_download_url);
|
|
@@ -16269,7 +16278,7 @@ function parseLatestGitHubRelease(value) {
|
|
|
16269
16278
|
}
|
|
16270
16279
|
const version2 = requireSemanticVersion(release.tag_name.slice(1));
|
|
16271
16280
|
const notesMatch = RELEASE_NOTES_URL_PATTERN.exec(release.html_url);
|
|
16272
|
-
if (!notesMatch || notesMatch[
|
|
16281
|
+
if (!notesMatch || notesMatch[2] !== release.tag_name) {
|
|
16273
16282
|
throw new Error("GitHub Release notes URL does not match its tag");
|
|
16274
16283
|
}
|
|
16275
16284
|
const releaseNotes = typeof release.body === "string" && release.body.trim().length > 0 ? release.body.slice(0, 2e4) : null;
|
|
@@ -16356,8 +16365,7 @@ function selectInstallerReleaseArtifact(release, target) {
|
|
|
16356
16365
|
const sha256 = digest?.[1];
|
|
16357
16366
|
if (!sha256)
|
|
16358
16367
|
throw new Error(`GitHub Release asset ${name} has no valid SHA-256 digest`);
|
|
16359
|
-
|
|
16360
|
-
if (!asset.downloadUrl.startsWith(expectedPrefix) || !asset.downloadUrl.endsWith(`/${name}`)) {
|
|
16368
|
+
if (!isBoftReleaseDownloadUrl(asset.downloadUrl, release.version) || !asset.downloadUrl.endsWith(`/${name}`)) {
|
|
16361
16369
|
throw new Error(`GitHub Release asset ${name} has an unexpected download URL`);
|
|
16362
16370
|
}
|
|
16363
16371
|
return Object.freeze({
|
package/app/console-web.js
CHANGED
|
@@ -15373,7 +15373,10 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
15373
15373
|
latestVersion: external_exports.string().min(1).max(128),
|
|
15374
15374
|
updateAvailable: external_exports.boolean(),
|
|
15375
15375
|
canUpdate: external_exports.boolean(),
|
|
15376
|
-
|
|
15376
|
+
// Adapter-owned diagnostic text; UI uses messageCode rather than displaying it verbatim.
|
|
15377
|
+
message: external_exports.string().max(2048).optional(),
|
|
15378
|
+
messageCode: external_exports.string().min(1).max(128).optional(),
|
|
15379
|
+
latestVersionKind: external_exports.enum(["unknown", "tracking-branch"]).optional()
|
|
15377
15380
|
}).strict();
|
|
15378
15381
|
|
|
15379
15382
|
// ../shared-contracts/dist/codex-accounts.js
|
|
@@ -15666,7 +15669,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
15666
15669
|
}
|
|
15667
15670
|
});
|
|
15668
15671
|
var updateEmptyParamsSchema = external_exports.strictObject({});
|
|
15669
|
-
var githubReleaseNotesUrlSchema = external_exports.string().max(300).regex(/^https:\/\/github\.com\/LiberSeek\/BOFT-CLI\/releases\/tag\/v[0-9A-Za-z.+-]+$/u, "release notes URL must identify a codexhost GitHub Release");
|
|
15672
|
+
var githubReleaseNotesUrlSchema = external_exports.string().max(300).regex(/^https:\/\/github\.com\/(LiberSeek|LIBERSEEK)\/BOFT-CLI\/releases\/tag\/v[0-9A-Za-z.+-]+$/u, "release notes URL must identify a codexhost GitHub Release");
|
|
15670
15673
|
var updateCheckResultSchema = external_exports.strictObject({
|
|
15671
15674
|
currentVersion: updateSemanticVersionSchema,
|
|
15672
15675
|
installation: updateInstallationSchema.nullable(),
|
|
@@ -18803,6 +18806,52 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
18803
18806
|
close: "\u5B8C\u6210"
|
|
18804
18807
|
};
|
|
18805
18808
|
|
|
18809
|
+
// src/settings/harness-version-messages.ts
|
|
18810
|
+
var harnessVersionEnglish = Object.freeze({
|
|
18811
|
+
unknown: "Unknown",
|
|
18812
|
+
trackingBranch: "Tracking branch (new commits)",
|
|
18813
|
+
notes: Object.freeze({
|
|
18814
|
+
"original-installer": "Use the original installer, package manager, or launcher to update this installation.",
|
|
18815
|
+
"claude-policy-restricted": "Claude updates are restricted by the installation's settings or policy.",
|
|
18816
|
+
"codebuddy-npm-required": "Use CodeBuddy's native updater or original package manager. Latest-version checks here require an identified npm installation.",
|
|
18817
|
+
"deepseek-original-installer": "Update with the original installer. Python, desktop, and project-local installations are not upgraded through global npm.",
|
|
18818
|
+
"kiro-native-updater": "Use Kiro CLI's original installer or native updater to check for and install updates.",
|
|
18819
|
+
"qoder-check-unavailable": "This Qoder China release does not expose a non-installing update check. Use its original installer.",
|
|
18820
|
+
"hermes-update-plan-unavailable": "This Hermes release does not expose a safe update plan. Use the original installer.",
|
|
18821
|
+
"hermes-externally-managed": "This Hermes installation is managed externally. Update it through its desktop app, container, or original package manager.",
|
|
18822
|
+
"hermes-update-channel": "Uses Hermes's configured update channel. Gateway restarts are deferred; existing processes keep their running code.",
|
|
18823
|
+
"hermes-manual-update": "Use the native updater manually. Safe non-interactive updates require a clean source checkout, commit identity, and Gateway restart deferral."
|
|
18824
|
+
})
|
|
18825
|
+
});
|
|
18826
|
+
var harnessVersionChinese = Object.freeze({
|
|
18827
|
+
unknown: "\u672A\u77E5",
|
|
18828
|
+
trackingBranch: "\u8DDF\u8E2A\u5206\u652F\uFF08\u6709\u65B0\u63D0\u4EA4\uFF09",
|
|
18829
|
+
notes: Object.freeze({
|
|
18830
|
+
"original-installer": "\u8BF7\u4F7F\u7528\u539F\u5B89\u88C5\u7A0B\u5E8F\u3001\u5305\u7BA1\u7406\u5668\u6216\u542F\u52A8\u5668\u66F4\u65B0\u6B64\u5B89\u88C5\u3002",
|
|
18831
|
+
"claude-policy-restricted": "\u6B64 Claude \u5B89\u88C5\u7684\u8BBE\u7F6E\u6216\u7B56\u7565\u9650\u5236\u4E86\u66F4\u65B0\u3002",
|
|
18832
|
+
"codebuddy-npm-required": "\u8BF7\u4F7F\u7528 CodeBuddy \u539F\u751F\u66F4\u65B0\u5668\u6216\u539F\u5305\u7BA1\u7406\u5668\u66F4\u65B0\u3002\u6B64\u5904\u4EC5\u80FD\u67E5\u8BE2\u5DF2\u8BC6\u522B\u7684 npm \u5B89\u88C5\u7684\u6700\u65B0\u7248\u672C\u3002",
|
|
18833
|
+
"deepseek-original-installer": "\u8BF7\u4F7F\u7528\u539F\u5B89\u88C5\u65B9\u5F0F\u66F4\u65B0\u3002Python\u3001\u684C\u9762\u5E94\u7528\u53CA\u9879\u76EE\u5185\u5B89\u88C5\u4E0D\u4F1A\u901A\u8FC7\u5168\u5C40 npm \u66F4\u65B0\u3002",
|
|
18834
|
+
"kiro-native-updater": "\u8BF7\u4F7F\u7528 Kiro CLI \u539F\u5B89\u88C5\u7A0B\u5E8F\u6216\u539F\u751F\u66F4\u65B0\u5668\u68C0\u67E5\u5E76\u5B89\u88C5\u66F4\u65B0\u3002",
|
|
18835
|
+
"qoder-check-unavailable": "\u6B64 Qoder \u4E2D\u56FD\u7248\u5C1A\u4E0D\u652F\u6301\u53EA\u68C0\u67E5\u3001\u4E0D\u5B89\u88C5\u7684\u66F4\u65B0\u67E5\u8BE2\uFF0C\u8BF7\u4F7F\u7528\u539F\u5B89\u88C5\u65B9\u5F0F\u66F4\u65B0\u3002",
|
|
18836
|
+
"hermes-update-plan-unavailable": "\u6B64 Hermes \u7248\u672C\u4E0D\u63D0\u4F9B\u5B89\u5168\u7684\u66F4\u65B0\u8BA1\u5212\uFF0C\u8BF7\u4F7F\u7528\u539F\u5B89\u88C5\u65B9\u5F0F\u66F4\u65B0\u3002",
|
|
18837
|
+
"hermes-externally-managed": "\u6B64 Hermes \u5B89\u88C5\u7531\u5916\u90E8\u5DE5\u5177\u7BA1\u7406\uFF0C\u8BF7\u901A\u8FC7\u5176\u684C\u9762\u5E94\u7528\u3001\u5BB9\u5668\u6216\u539F\u5305\u7BA1\u7406\u5668\u66F4\u65B0\u3002",
|
|
18838
|
+
"hermes-update-channel": "\u4F7F\u7528 Hermes \u914D\u7F6E\u7684\u66F4\u65B0\u6E20\u9053\uFF0C\u6682\u4E0D\u91CD\u542F Gateway\uFF1B\u73B0\u6709\u8FDB\u7A0B\u7EE7\u7EED\u8FD0\u884C\u539F\u6709\u4EE3\u7801\u3002",
|
|
18839
|
+
"hermes-manual-update": "\u8BF7\u624B\u52A8\u4F7F\u7528\u539F\u751F\u66F4\u65B0\u5668\u3002\u5B89\u5168\u7684\u975E\u4EA4\u4E92\u66F4\u65B0\u8981\u6C42\u6E90\u7801\u76EE\u5F55\u65E0\u672A\u63D0\u4EA4\u4FEE\u6539\u3001\u53EF\u8BC6\u522B\u5F53\u524D\u63D0\u4EA4\uFF0C\u5E76\u652F\u6301\u63A8\u8FDF Gateway \u91CD\u542F\u3002"
|
|
18840
|
+
})
|
|
18841
|
+
});
|
|
18842
|
+
function harnessVersionLabel(state, messages) {
|
|
18843
|
+
if (!state) return "\u2014";
|
|
18844
|
+
if (state.latestVersionKind === "unknown" || state.latestVersion === "Unknown")
|
|
18845
|
+
return messages.unknown;
|
|
18846
|
+
if (state.latestVersionKind === "tracking-branch" || state.latestVersion === "Tracking branch (new commits)")
|
|
18847
|
+
return messages.trackingBranch;
|
|
18848
|
+
return state.latestVersion;
|
|
18849
|
+
}
|
|
18850
|
+
function harnessVersionNote(state, messages) {
|
|
18851
|
+
const code = state?.messageCode;
|
|
18852
|
+
return code && Object.hasOwn(messages.notes, code) ? messages.notes[code] : void 0;
|
|
18853
|
+
}
|
|
18854
|
+
|
|
18806
18855
|
// src/settings/localization.ts
|
|
18807
18856
|
var ENGLISH_MESSAGES = Object.freeze({
|
|
18808
18857
|
credentialImports: credentialImportEnglish,
|
|
@@ -18953,15 +19002,14 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
18953
19002
|
connectionCopyDetails: "Copy diagnostics",
|
|
18954
19003
|
connectionCopied: "Copied",
|
|
18955
19004
|
connectionCopyFailed: "Copy failed",
|
|
18956
|
-
connectionErrorCode: "Error code",
|
|
18957
19005
|
connectionErrorMessage: "Error message",
|
|
18958
|
-
connectionRetryable: "Retryable",
|
|
18959
|
-
connectionFailureStage: "Failure stage",
|
|
18960
|
-
connectionDuration: "Duration",
|
|
18961
|
-
connectionDiagnostic: "Diagnostic",
|
|
18962
19006
|
connectionNoRuntime: "The renderer request bridge is not available yet.",
|
|
18963
19007
|
connectionStatusReady: "Ready",
|
|
18964
19008
|
connectionStatusConnected: "Connected",
|
|
19009
|
+
connectionLoginRequired: "Login required",
|
|
19010
|
+
connectionConfigurationRequired: "Setup required",
|
|
19011
|
+
connectionConfigurationDescription: "Configure a Provider and its required credentials in this Harness on the selected Host, then check the connection again.",
|
|
19012
|
+
connectionLoginDescription: "Complete login or authentication setup in this Harness on the selected Host, then check the connection again.",
|
|
18965
19013
|
connectionStatusChecking: "Checking",
|
|
18966
19014
|
connectionStatusNotInstalled: "Not installed",
|
|
18967
19015
|
connectionStatusUnavailable: "Unavailable",
|
|
@@ -19000,6 +19048,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
19000
19048
|
connectionCopyPrompt: "Copy prompt",
|
|
19001
19049
|
connectionInstallPrompt: "Please install {name} (CLI command: {binary}) on this machine.\n\nUse the official install method and run:\n{command}\n\nOfficial installation page: {url}\n\nAfter installation, verify that `{binary}` is available in the terminal and report the result.",
|
|
19002
19050
|
connectionInstallRunning: "Installing on the selected Host. You can leave this page; login or setup may still be required afterward.",
|
|
19051
|
+
harnessVersion: harnessVersionEnglish,
|
|
19003
19052
|
harnessVersionTitle: "Harness CLI version",
|
|
19004
19053
|
harnessVersionCurrent: "Current version",
|
|
19005
19054
|
harnessVersionLatest: "Latest version",
|
|
@@ -19255,15 +19304,14 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
19255
19304
|
connectionCopyDetails: "\u590D\u5236\u8BCA\u65AD\u4FE1\u606F",
|
|
19256
19305
|
connectionCopied: "\u5DF2\u590D\u5236",
|
|
19257
19306
|
connectionCopyFailed: "\u590D\u5236\u5931\u8D25",
|
|
19258
|
-
connectionErrorCode: "\u9519\u8BEF\u7801",
|
|
19259
19307
|
connectionErrorMessage: "\u9519\u8BEF\u4FE1\u606F",
|
|
19260
|
-
connectionRetryable: "\u53EF\u91CD\u8BD5",
|
|
19261
|
-
connectionFailureStage: "\u5931\u8D25\u9636\u6BB5",
|
|
19262
|
-
connectionDuration: "\u68C0\u67E5\u8017\u65F6",
|
|
19263
|
-
connectionDiagnostic: "\u8BCA\u65AD\u4FE1\u606F",
|
|
19264
19308
|
connectionNoRuntime: "Renderer \u8BF7\u6C42\u6865\u5C1A\u672A\u53EF\u7528\u3002",
|
|
19265
19309
|
connectionStatusReady: "\u6B63\u5E38",
|
|
19266
19310
|
connectionStatusConnected: "\u5DF2\u8FDE\u63A5",
|
|
19311
|
+
connectionLoginRequired: "\u9700\u8981\u767B\u5F55",
|
|
19312
|
+
connectionConfigurationRequired: "\u9700\u8981\u914D\u7F6E",
|
|
19313
|
+
connectionConfigurationDescription: "\u8BF7\u5728\u6240\u9009 Host \u4E0A\u914D\u7F6E\u8BE5 Harness \u7684 Provider \u53CA\u6240\u9700\u8BA4\u8BC1\u4FE1\u606F\uFF0C\u7136\u540E\u91CD\u65B0\u68C0\u6D4B\u8FDE\u63A5\u3002",
|
|
19314
|
+
connectionLoginDescription: "\u8BF7\u5728\u6240\u9009 Host \u4E0A\u5B8C\u6210\u8BE5 Harness \u7684\u767B\u5F55\u6216\u8BA4\u8BC1\u914D\u7F6E\uFF0C\u7136\u540E\u91CD\u65B0\u68C0\u6D4B\u8FDE\u63A5\u3002",
|
|
19267
19315
|
connectionStatusChecking: "\u68C0\u67E5\u4E2D",
|
|
19268
19316
|
connectionStatusNotInstalled: "\u672A\u5B89\u88C5",
|
|
19269
19317
|
connectionStatusUnavailable: "\u4E0D\u53EF\u7528",
|
|
@@ -19302,6 +19350,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
19302
19350
|
connectionCopyPrompt: "\u590D\u5236 Prompt",
|
|
19303
19351
|
connectionInstallPrompt: "\u8BF7\u5E2E\u6211\u5728\u672C\u673A\u5B89\u88C5 {name}\uFF08CLI \u547D\u4EE4\uFF1A{binary}\uFF09\u3002\n\n\u8BF7\u6309\u5B98\u65B9\u5B89\u88C5\u65B9\u5F0F\u6267\u884C\u4EE5\u4E0B\u547D\u4EE4\uFF0C\u5E76\u5904\u7406 PATH\u3001\u6743\u9650\u548C\u4F9D\u8D56\u95EE\u9898\uFF1A\n{command}\n\n\u5B98\u65B9\u5B89\u88C5\u9875\u9762\uFF1A{url}\n\n\u5B89\u88C5\u5B8C\u6210\u540E\u8BF7\u9A8C\u8BC1 `{binary}` \u53EF\u4EE5\u5728\u7EC8\u7AEF\u4E2D\u8FD0\u884C\uFF0C\u5E76\u544A\u8BC9\u6211\u7ED3\u679C\u3002",
|
|
19304
19352
|
connectionInstallRunning: "\u6B63\u5728\u6240\u9009 Host \u4E0A\u5B89\u88C5\uFF0C\u79BB\u5F00\u9875\u9762\u4E0D\u4F1A\u4E2D\u65AD\u3002\u5B89\u88C5\u540E\u53EF\u80FD\u4ECD\u9700\u767B\u5F55\u6216\u914D\u7F6E\u3002",
|
|
19353
|
+
harnessVersion: harnessVersionChinese,
|
|
19305
19354
|
harnessVersionTitle: "Harness CLI \u7248\u672C",
|
|
19306
19355
|
harnessVersionCurrent: "\u5F53\u524D\u7248\u672C",
|
|
19307
19356
|
harnessVersionLatest: "\u6700\u65B0\u7248\u672C",
|
|
@@ -19912,7 +19961,7 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
19912
19961
|
}
|
|
19913
19962
|
|
|
19914
19963
|
// src/settings/harness-installation-panel.ts
|
|
19915
|
-
function createHarnessInstallationPanel(document2, agent, hostId, messages, copy, refresh) {
|
|
19964
|
+
function createHarnessInstallationPanel(document2, agent, hostId, messages, copy, installation, refresh) {
|
|
19916
19965
|
const zh = messages.locale === "zh-CN";
|
|
19917
19966
|
const guide = harnessInstallationGuide(agent, messages.locale);
|
|
19918
19967
|
const panel = document2.createElement("div");
|
|
@@ -19926,6 +19975,21 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
19926
19975
|
paragraph(zh ? "\u8BF7\u5728\u8FDC\u7A0B Host \u4E0A\u5B89\u88C5\u3002" : "Install on the remote Host.");
|
|
19927
19976
|
}
|
|
19928
19977
|
if (guide.before) paragraph(guide.before);
|
|
19978
|
+
const install = installation && guide.commands.length > 0 ? document2.createElement("button") : null;
|
|
19979
|
+
if (install && installation) {
|
|
19980
|
+
install.type = "button";
|
|
19981
|
+
install.className = "settings-command-button";
|
|
19982
|
+
install.dataset.connectionAction = "install";
|
|
19983
|
+
install.disabled = installation.status !== "idle";
|
|
19984
|
+
install.textContent = installation.status === "installing" ? messages.connectionStatusInstalling : installation.status === "checking" ? messages.connectionStatusChecking : zh ? "\u4E00\u952E\u5B89\u88C5" : "Install automatically";
|
|
19985
|
+
install.addEventListener("click", () => {
|
|
19986
|
+
if (install.disabled) return;
|
|
19987
|
+
install.disabled = true;
|
|
19988
|
+
install.textContent = messages.connectionStatusInstalling;
|
|
19989
|
+
installation.run();
|
|
19990
|
+
});
|
|
19991
|
+
if (guide.commands.length > 1) panel.append(install);
|
|
19992
|
+
}
|
|
19929
19993
|
for (const { terminal, command } of guide.commands) {
|
|
19930
19994
|
const block = document2.createElement("div");
|
|
19931
19995
|
block.className = "settings-harness-installation-command";
|
|
@@ -19943,7 +20007,11 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
19943
20007
|
button2.setAttribute("aria-label", `${copyLabel}: ${terminal}`);
|
|
19944
20008
|
button2.append(createRendererSettingsIcon("copy", 16), copyLabel);
|
|
19945
20009
|
button2.addEventListener("click", () => copy(button2, command, copyLabel));
|
|
19946
|
-
|
|
20010
|
+
const actions = document2.createElement("div");
|
|
20011
|
+
actions.className = "settings-harness-installation-actions";
|
|
20012
|
+
if (install && guide.commands.length === 1) actions.append(install);
|
|
20013
|
+
actions.append(button2);
|
|
20014
|
+
block.append(label, pre, actions);
|
|
19947
20015
|
panel.append(block);
|
|
19948
20016
|
}
|
|
19949
20017
|
const link = (url2, label) => {
|
|
@@ -19962,17 +20030,19 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
19962
20030
|
);
|
|
19963
20031
|
}
|
|
19964
20032
|
paragraph(guide.after);
|
|
19965
|
-
|
|
19966
|
-
|
|
19967
|
-
|
|
19968
|
-
|
|
19969
|
-
|
|
19970
|
-
|
|
19971
|
-
check2.
|
|
19972
|
-
|
|
19973
|
-
|
|
19974
|
-
|
|
19975
|
-
|
|
20033
|
+
if (refresh) {
|
|
20034
|
+
const check2 = document2.createElement("button");
|
|
20035
|
+
check2.type = "button";
|
|
20036
|
+
check2.className = "settings-command-button";
|
|
20037
|
+
check2.dataset.connectionAction = "check-install";
|
|
20038
|
+
check2.textContent = zh ? "\u91CD\u65B0\u68C0\u6D4B" : "Check again";
|
|
20039
|
+
check2.addEventListener("click", () => {
|
|
20040
|
+
check2.disabled = true;
|
|
20041
|
+
check2.textContent = messages.connectionRefreshing;
|
|
20042
|
+
refresh();
|
|
20043
|
+
});
|
|
20044
|
+
panel.append(check2);
|
|
20045
|
+
}
|
|
19976
20046
|
link(guide.url, zh ? "\u67E5\u770B\u5B98\u65B9\u5B89\u88C5\u8BF4\u660E" : "View official installation instructions");
|
|
19977
20047
|
return panel;
|
|
19978
20048
|
}
|
|
@@ -20300,10 +20370,11 @@ Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.
|
|
|
20300
20370
|
let unsupported = false;
|
|
20301
20371
|
const render = () => {
|
|
20302
20372
|
current.textContent = `${messages.harnessVersionCurrent}: ${state?.currentVersion ?? "\u2014"}`;
|
|
20303
|
-
latest.textContent = `${messages.harnessVersionLatest}: ${state
|
|
20373
|
+
latest.textContent = `${messages.harnessVersionLatest}: ${harnessVersionLabel(state, messages.harnessVersion)}`;
|
|
20304
20374
|
update.disabled = busy || signal.aborted || !state?.canUpdate || !state.updateAvailable;
|
|
20305
20375
|
update.textContent = state?.canUpdate && state.latestVersion !== "Unknown" && !state.updateAvailable ? messages.harnessVersionUpToDate : messages.harnessVersionUpdate;
|
|
20306
|
-
|
|
20376
|
+
const detail = harnessVersionNote(state, messages.harnessVersion);
|
|
20377
|
+
note.textContent = detail ? `${detail} ${messages.harnessVersionNote}` : messages.harnessVersionNote;
|
|
20307
20378
|
};
|
|
20308
20379
|
const run = async (action) => {
|
|
20309
20380
|
if (busy || unsupported || signal.aborted) return;
|
|
@@ -20371,16 +20442,6 @@ ${error51.stderrTail}`] : []
|
|
|
20371
20442
|
] : []
|
|
20372
20443
|
].join("\n");
|
|
20373
20444
|
}
|
|
20374
|
-
function detailLine(document2, label, value) {
|
|
20375
|
-
const line = document2.createElement("div");
|
|
20376
|
-
line.className = "settings-connection-detail-line";
|
|
20377
|
-
const name = document2.createElement("span");
|
|
20378
|
-
name.textContent = label;
|
|
20379
|
-
const content = document2.createElement("code");
|
|
20380
|
-
content.textContent = value;
|
|
20381
|
-
line.append(name, content);
|
|
20382
|
-
return line;
|
|
20383
|
-
}
|
|
20384
20445
|
function setActionButtonLabel(button2, icon, label) {
|
|
20385
20446
|
button2.replaceChildren(createRendererSettingsIcon(icon, 16), label);
|
|
20386
20447
|
}
|
|
@@ -20572,30 +20633,15 @@ ${error51.stderrTail}`] : []
|
|
|
20572
20633
|
}
|
|
20573
20634
|
return body;
|
|
20574
20635
|
}
|
|
20636
|
+
const needsLogin = item.error.code === "authenticationRequired";
|
|
20637
|
+
const needsConfiguration = item.error.code === "configurationRequired";
|
|
20575
20638
|
const summary = document2.createElement("div");
|
|
20576
20639
|
summary.className = "settings-connection-error-summary";
|
|
20577
20640
|
const title = document2.createElement("strong");
|
|
20578
|
-
title.textContent = messages.connectionErrorTitle;
|
|
20641
|
+
title.textContent = needsLogin ? messages.connectionLoginRequired : needsConfiguration ? messages.connectionConfigurationRequired : messages.connectionErrorTitle;
|
|
20579
20642
|
const description = document2.createElement("p");
|
|
20580
|
-
description.textContent = item.error.message;
|
|
20643
|
+
description.textContent = needsLogin ? messages.connectionLoginDescription : needsConfiguration ? messages.connectionConfigurationDescription : item.error.message;
|
|
20581
20644
|
summary.append(title, description);
|
|
20582
|
-
const metadata = document2.createElement("div");
|
|
20583
|
-
metadata.className = "settings-connection-error-metadata";
|
|
20584
|
-
metadata.append(
|
|
20585
|
-
detailLine(document2, messages.connectionErrorCode, item.error.code),
|
|
20586
|
-
detailLine(document2, messages.connectionRetryable, String(item.error.retryable))
|
|
20587
|
-
);
|
|
20588
|
-
if (item.error.stage) {
|
|
20589
|
-
metadata.append(detailLine(document2, messages.connectionFailureStage, item.error.stage));
|
|
20590
|
-
}
|
|
20591
|
-
if (item.error.durationMs !== void 0) {
|
|
20592
|
-
metadata.append(
|
|
20593
|
-
detailLine(document2, messages.connectionDuration, `${item.error.durationMs} ms`)
|
|
20594
|
-
);
|
|
20595
|
-
}
|
|
20596
|
-
if (item.error.diagnostic) {
|
|
20597
|
-
metadata.append(detailLine(document2, messages.connectionDiagnostic, item.error.diagnostic));
|
|
20598
|
-
}
|
|
20599
20645
|
const logHeader = document2.createElement("div");
|
|
20600
20646
|
logHeader.className = "settings-connection-error-log-header";
|
|
20601
20647
|
const logTitle = document2.createElement("strong");
|
|
@@ -20611,7 +20657,7 @@ ${error51.stderrTail}`] : []
|
|
|
20611
20657
|
logHeader.append(logTitle, copy);
|
|
20612
20658
|
const log = document2.createElement("pre");
|
|
20613
20659
|
log.className = "settings-connection-stderr";
|
|
20614
|
-
log.textContent =
|
|
20660
|
+
log.textContent = report;
|
|
20615
20661
|
const actions = document2.createElement("div");
|
|
20616
20662
|
actions.className = "settings-connection-error-actions";
|
|
20617
20663
|
const issue2 = document2.createElement("a");
|
|
@@ -20624,7 +20670,7 @@ ${error51.stderrTail}`] : []
|
|
|
20624
20670
|
const issueNote = document2.createElement("p");
|
|
20625
20671
|
issueNote.className = "settings-connection-issue-note";
|
|
20626
20672
|
issueNote.textContent = messages.connectionIssueDescription;
|
|
20627
|
-
body.append(summary,
|
|
20673
|
+
body.append(summary, logHeader, log, actions, issueNote);
|
|
20628
20674
|
return body;
|
|
20629
20675
|
}
|
|
20630
20676
|
function createConnectionBlock(document2, item, hostId, messages, expanded, toggleExpand, group = null, launchControls = null, versionCapable = false, detailNodes = [], longContext = null) {
|
|
@@ -20655,7 +20701,7 @@ ${error51.stderrTail}`] : []
|
|
|
20655
20701
|
status.className = "settings-connection-row__status";
|
|
20656
20702
|
status.dataset.connectionTone = connectionStatusTone(item.availability, item.error !== null);
|
|
20657
20703
|
status.setAttribute("role", "cell");
|
|
20658
|
-
status.textContent = connectionStatusLabel(item.availability, messages, item.error !== null);
|
|
20704
|
+
status.textContent = item.error?.code === "authenticationRequired" ? messages.connectionLoginRequired : item.error?.code === "configurationRequired" ? messages.connectionConfigurationRequired : connectionStatusLabel(item.availability, messages, item.error !== null);
|
|
20659
20705
|
const action = document2.createElement("div");
|
|
20660
20706
|
action.className = "settings-connection-row__action";
|
|
20661
20707
|
action.setAttribute("role", "cell");
|
|
@@ -20959,6 +21005,9 @@ ${error51.stderrTail}`] : []
|
|
|
20959
21005
|
const nodes = [];
|
|
20960
21006
|
const agent = item.agentSnapshot?.agent;
|
|
20961
21007
|
if (expanded && agent && item.availability === "notInstalled") {
|
|
21008
|
+
const installState = installs?.get(selectedHost.hostId, agent);
|
|
21009
|
+
const canInstall = selectedHost.hostId === "local" && agent !== "workbuddy" && diagnostics?.installation !== void 0;
|
|
21010
|
+
const installStatus = installState?.status === "installing" || installState?.status === "checking" ? installState.status : "idle";
|
|
20962
21011
|
nodes.push(
|
|
20963
21012
|
createHarnessInstallationPanel(
|
|
20964
21013
|
document2,
|
|
@@ -20966,35 +21015,26 @@ ${error51.stderrTail}`] : []
|
|
|
20966
21015
|
selectedHost.hostId,
|
|
20967
21016
|
messages,
|
|
20968
21017
|
(button2, command, label) => copyTextToClipboard(document2, button2, command, messages, label),
|
|
21018
|
+
canInstall ? {
|
|
21019
|
+
run: () => {
|
|
21020
|
+
void installs?.install(selectedHost.hostId, agent);
|
|
21021
|
+
},
|
|
21022
|
+
status: installStatus
|
|
21023
|
+
} : void 0,
|
|
20969
21024
|
runRefresh
|
|
20970
21025
|
)
|
|
20971
21026
|
);
|
|
20972
|
-
|
|
20973
|
-
|
|
20974
|
-
|
|
20975
|
-
|
|
20976
|
-
|
|
20977
|
-
|
|
20978
|
-
|
|
20979
|
-
|
|
20980
|
-
|
|
20981
|
-
|
|
20982
|
-
|
|
20983
|
-
if (busy) {
|
|
20984
|
-
const note = document2.createElement("p");
|
|
20985
|
-
note.textContent = messages.connectionInstallRunning;
|
|
20986
|
-
nodes.push(note);
|
|
20987
|
-
}
|
|
20988
|
-
const installNow = document2.createElement("button");
|
|
20989
|
-
installNow.type = "button";
|
|
20990
|
-
installNow.className = "settings-command-button";
|
|
20991
|
-
installNow.dataset.connectionAction = "run-install";
|
|
20992
|
-
installNow.disabled = busy;
|
|
20993
|
-
installNow.textContent = busy ? messages.connectionInstallRunning : messages.connectionInstall;
|
|
20994
|
-
installNow.addEventListener("click", () => {
|
|
20995
|
-
void installs?.install(selectedHost.hostId, agent);
|
|
20996
|
-
});
|
|
20997
|
-
nodes.push(installNow);
|
|
21027
|
+
if (canInstall && installState?.error) {
|
|
21028
|
+
const error51 = document2.createElement("p");
|
|
21029
|
+
error51.className = "settings-connection-install-error";
|
|
21030
|
+
error51.setAttribute("role", "alert");
|
|
21031
|
+
error51.textContent = installState.error;
|
|
21032
|
+
nodes.push(error51);
|
|
21033
|
+
}
|
|
21034
|
+
if (canInstall && installStatus !== "idle") {
|
|
21035
|
+
const note = document2.createElement("p");
|
|
21036
|
+
note.textContent = messages.connectionInstallRunning;
|
|
21037
|
+
nodes.push(note);
|
|
20998
21038
|
}
|
|
20999
21039
|
}
|
|
21000
21040
|
const installation = diagnostics?.installation?.bind(diagnostics);
|
|
@@ -24411,6 +24451,16 @@ ${error51.stderrTail}`] : []
|
|
|
24411
24451
|
messages.updateDownloadFromReleases,
|
|
24412
24452
|
createRendererSettingsIcon("external-link", 14)
|
|
24413
24453
|
);
|
|
24454
|
+
releaseLink.addEventListener("click", (event) => {
|
|
24455
|
+
const open = getClient()?.openExternalUrl;
|
|
24456
|
+
if (!open) return;
|
|
24457
|
+
event.preventDefault();
|
|
24458
|
+
const url2 = releaseLink.href;
|
|
24459
|
+
void open(url2).catch((error51) => {
|
|
24460
|
+
console.error("codexhost external URL open failed", error51);
|
|
24461
|
+
document2.defaultView?.open(url2, "_blank", "noopener,noreferrer");
|
|
24462
|
+
});
|
|
24463
|
+
});
|
|
24414
24464
|
actions.append(releaseLink);
|
|
24415
24465
|
controls.append(manualTitle, manualNpm, manualWindowsInstaller, actions);
|
|
24416
24466
|
const notes = document2.createElement("div");
|
|
@@ -25752,6 +25802,12 @@ ${error51.stderrTail}`] : []
|
|
|
25752
25802
|
border-radius: 10px;
|
|
25753
25803
|
}
|
|
25754
25804
|
|
|
25805
|
+
.settings-harness-installation-actions {
|
|
25806
|
+
display: flex;
|
|
25807
|
+
flex-wrap: wrap;
|
|
25808
|
+
gap: 8px;
|
|
25809
|
+
}
|
|
25810
|
+
|
|
25755
25811
|
.settings-harness-installation-command pre {
|
|
25756
25812
|
white-space: pre-wrap;
|
|
25757
25813
|
overflow-wrap: anywhere;
|
|
@@ -26174,33 +26230,6 @@ ${error51.stderrTail}`] : []
|
|
|
26174
26230
|
border-radius: 10px;
|
|
26175
26231
|
}
|
|
26176
26232
|
|
|
26177
|
-
.settings-connection-error-metadata {
|
|
26178
|
-
display: grid;
|
|
26179
|
-
gap: 7px;
|
|
26180
|
-
padding: 12px;
|
|
26181
|
-
background: var(--settings-inset);
|
|
26182
|
-
border: 1px solid var(--settings-border);
|
|
26183
|
-
border-radius: 9px;
|
|
26184
|
-
}
|
|
26185
|
-
|
|
26186
|
-
.settings-connection-detail-line {
|
|
26187
|
-
display: grid;
|
|
26188
|
-
grid-template-columns: 92px minmax(0, 1fr);
|
|
26189
|
-
gap: 10px;
|
|
26190
|
-
min-width: 0;
|
|
26191
|
-
color: var(--settings-muted);
|
|
26192
|
-
font-size: 10px;
|
|
26193
|
-
line-height: 16px;
|
|
26194
|
-
}
|
|
26195
|
-
|
|
26196
|
-
.settings-connection-detail-line code {
|
|
26197
|
-
min-width: 0;
|
|
26198
|
-
overflow-wrap: anywhere;
|
|
26199
|
-
color: var(--settings-text);
|
|
26200
|
-
font-family: ui-monospace, "SFMono-Regular", Consolas, "Liberation Mono", monospace;
|
|
26201
|
-
white-space: pre-wrap;
|
|
26202
|
-
}
|
|
26203
|
-
|
|
26204
26233
|
.settings-connection-error-log-header {
|
|
26205
26234
|
display: flex;
|
|
26206
26235
|
align-items: center;
|
|
@@ -1216,6 +1216,14 @@ function installRendererHostRouting(root, target, discover, resolve, createPolic
|
|
|
1216
1216
|
return typeof hostId === "string" && hostId ? hostId : null;
|
|
1217
1217
|
};
|
|
1218
1218
|
const routing = {
|
|
1219
|
+
knownHostIds() {
|
|
1220
|
+
if (disposed) return [];
|
|
1221
|
+
try {
|
|
1222
|
+
return [...read().hostIds];
|
|
1223
|
+
} catch {
|
|
1224
|
+
return [];
|
|
1225
|
+
}
|
|
1226
|
+
},
|
|
1219
1227
|
forHost(hostId) {
|
|
1220
1228
|
return hostId ? routeFor(hostId) : null;
|
|
1221
1229
|
},
|
|
@@ -1282,7 +1290,12 @@ function directRendererInstaller() {
|
|
|
1282
1290
|
manager, bridge, hostId, target, prewarmed, isCurrent, retainRendererHostResponses,
|
|
1283
1291
|
),
|
|
1284
1292
|
);
|
|
1285
|
-
|
|
1293
|
+
// Publish a default draft policy only when its Host is unambiguous. Host
|
|
1294
|
+
// connections can be ready even when multiple Composers coexist.
|
|
1295
|
+
const composerRoute = routing.forComposer();
|
|
1296
|
+
const connected = composerRoute !== null ||
|
|
1297
|
+
['local', ...(routing.knownHostIds?.() ?? [])].some((hostId) => routing.forHost(hostId) !== null);
|
|
1298
|
+
if (!connected) throw new Error('Renderer Host request manager is unavailable');
|
|
1286
1299
|
return { state: 'ready', reason: 'owned-request-bridge' };
|
|
1287
1300
|
})()`;
|
|
1288
1301
|
}
|
|
@@ -1298,7 +1311,8 @@ async function waitForDraftPrewarmPolicy(evaluate, expression) {
|
|
|
1298
1311
|
} catch (error) {
|
|
1299
1312
|
const message = error instanceof Error ? error.message : String(error);
|
|
1300
1313
|
const remaining = deadline - Date.now();
|
|
1301
|
-
if (!message.includes("Renderer request manager is
|
|
1314
|
+
if (!message.includes("Renderer Host request manager is unavailable") || remaining <= 0)
|
|
1315
|
+
throw error;
|
|
1302
1316
|
await new Promise(
|
|
1303
1317
|
(resolve) => setTimeout(resolve, Math.min(REQUEST_MANAGER_POLL_INTERVAL_MS, remaining))
|
|
1304
1318
|
);
|
package/app/host-runtime.mjs
CHANGED
|
@@ -4616,8 +4616,14 @@ async function resolveInstalledUpdateContext(options2) {
|
|
|
4616
4616
|
// packages/update-manager/dist/github-release.js
|
|
4617
4617
|
var CODEXHOST_LATEST_RELEASE_URL = "https://api.github.com/repos/LiberSeek/BOFT-CLI/releases/latest";
|
|
4618
4618
|
var SHA256_DIGEST_PATTERN = /^sha256:([0-9a-f]{64})$/u;
|
|
4619
|
-
var RELEASE_NOTES_URL_PATTERN = /^https:\/\/github\.com\/LiberSeek\/BOFT-CLI\/releases\/tag\/(v[0-9A-Za-z.+-]+)$/u;
|
|
4620
|
-
var
|
|
4619
|
+
var RELEASE_NOTES_URL_PATTERN = /^https:\/\/github\.com\/(LiberSeek|LIBERSEEK)\/BOFT-CLI\/releases\/tag\/(v[0-9A-Za-z.+-]+)$/u;
|
|
4620
|
+
var DOWNLOAD_URL_PREFIXES = [
|
|
4621
|
+
"https://github.com/LiberSeek/BOFT-CLI/releases/download/",
|
|
4622
|
+
"https://github.com/LIBERSEEK/BOFT-CLI/releases/download/"
|
|
4623
|
+
];
|
|
4624
|
+
function isBoftReleaseDownloadUrl(url2, version2) {
|
|
4625
|
+
return DOWNLOAD_URL_PREFIXES.some((prefix) => url2.startsWith(version2 === void 0 ? prefix : `${prefix}v${version2}/`));
|
|
4626
|
+
}
|
|
4621
4627
|
function record(value2, label) {
|
|
4622
4628
|
if (typeof value2 !== "object" || value2 === null || Array.isArray(value2)) {
|
|
4623
4629
|
throw new Error(`${label} must be an object`);
|
|
@@ -4626,7 +4632,7 @@ function record(value2, label) {
|
|
|
4626
4632
|
}
|
|
4627
4633
|
function releaseAsset(value2) {
|
|
4628
4634
|
const asset = record(value2, "GitHub Release asset");
|
|
4629
|
-
if (typeof asset.name !== "string" || asset.name.length === 0 || asset.name.length > 160 || !Number.isSafeInteger(asset.size) || asset.size <= 0 || asset.size > 2 * 1024 * 1024 * 1024 || asset.digest != null && typeof asset.digest !== "string" || typeof asset.browser_download_url !== "string" || !asset.browser_download_url
|
|
4635
|
+
if (typeof asset.name !== "string" || asset.name.length === 0 || asset.name.length > 160 || !Number.isSafeInteger(asset.size) || asset.size <= 0 || asset.size > 2 * 1024 * 1024 * 1024 || asset.digest != null && typeof asset.digest !== "string" || typeof asset.browser_download_url !== "string" || !isBoftReleaseDownloadUrl(asset.browser_download_url)) {
|
|
4630
4636
|
throw new Error("GitHub Release asset is invalid");
|
|
4631
4637
|
}
|
|
4632
4638
|
const url2 = new URL(asset.browser_download_url);
|
|
@@ -4647,7 +4653,7 @@ function parseLatestGitHubRelease(value2) {
|
|
|
4647
4653
|
}
|
|
4648
4654
|
const version2 = requireSemanticVersion(release.tag_name.slice(1));
|
|
4649
4655
|
const notesMatch = RELEASE_NOTES_URL_PATTERN.exec(release.html_url);
|
|
4650
|
-
if (!notesMatch || notesMatch[
|
|
4656
|
+
if (!notesMatch || notesMatch[2] !== release.tag_name) {
|
|
4651
4657
|
throw new Error("GitHub Release notes URL does not match its tag");
|
|
4652
4658
|
}
|
|
4653
4659
|
const releaseNotes = typeof release.body === "string" && release.body.trim().length > 0 ? release.body.slice(0, 2e4) : null;
|
|
@@ -4734,8 +4740,7 @@ function selectInstallerReleaseArtifact(release, target) {
|
|
|
4734
4740
|
const sha256 = digest2?.[1];
|
|
4735
4741
|
if (!sha256)
|
|
4736
4742
|
throw new Error(`GitHub Release asset ${name} has no valid SHA-256 digest`);
|
|
4737
|
-
|
|
4738
|
-
if (!asset.downloadUrl.startsWith(expectedPrefix) || !asset.downloadUrl.endsWith(`/${name}`)) {
|
|
4743
|
+
if (!isBoftReleaseDownloadUrl(asset.downloadUrl, release.version) || !asset.downloadUrl.endsWith(`/${name}`)) {
|
|
4739
4744
|
throw new Error(`GitHub Release asset ${name} has an unexpected download URL`);
|
|
4740
4745
|
}
|
|
4741
4746
|
return Object.freeze({
|
|
@@ -20667,7 +20672,10 @@ var harnessInstallationStateSchema = external_exports.object({
|
|
|
20667
20672
|
latestVersion: external_exports.string().min(1).max(128),
|
|
20668
20673
|
updateAvailable: external_exports.boolean(),
|
|
20669
20674
|
canUpdate: external_exports.boolean(),
|
|
20670
|
-
|
|
20675
|
+
// Adapter-owned diagnostic text; UI uses messageCode rather than displaying it verbatim.
|
|
20676
|
+
message: external_exports.string().max(2048).optional(),
|
|
20677
|
+
messageCode: external_exports.string().min(1).max(128).optional(),
|
|
20678
|
+
latestVersionKind: external_exports.enum(["unknown", "tracking-branch"]).optional()
|
|
20671
20679
|
}).strict();
|
|
20672
20680
|
|
|
20673
20681
|
// packages/shared-contracts/dist/codex-accounts.js
|
|
@@ -20967,7 +20975,7 @@ var updateStatusSchema = external_exports.strictObject({
|
|
|
20967
20975
|
}
|
|
20968
20976
|
});
|
|
20969
20977
|
var updateEmptyParamsSchema = external_exports.strictObject({});
|
|
20970
|
-
var githubReleaseNotesUrlSchema = external_exports.string().max(300).regex(/^https:\/\/github\.com\/LiberSeek\/BOFT-CLI\/releases\/tag\/v[0-9A-Za-z.+-]+$/u, "release notes URL must identify a codexhost GitHub Release");
|
|
20978
|
+
var githubReleaseNotesUrlSchema = external_exports.string().max(300).regex(/^https:\/\/github\.com\/(LiberSeek|LIBERSEEK)\/BOFT-CLI\/releases\/tag\/v[0-9A-Za-z.+-]+$/u, "release notes URL must identify a codexhost GitHub Release");
|
|
20971
20979
|
var updateCheckResultSchema = external_exports.strictObject({
|
|
20972
20980
|
currentVersion: updateSemanticVersionSchema,
|
|
20973
20981
|
installation: updateInstallationSchema.nullable(),
|
|
@@ -25596,6 +25604,7 @@ function mapExternalThreadHarnessError(error51, operation) {
|
|
|
25596
25604
|
case "notInstalled":
|
|
25597
25605
|
case "unavailable":
|
|
25598
25606
|
case "authenticationRequired":
|
|
25607
|
+
case "configurationRequired":
|
|
25599
25608
|
return { code: -32077, message: "External Harness is unavailable" };
|
|
25600
25609
|
case "nativeFailure":
|
|
25601
25610
|
case "protocolError":
|
|
@@ -15706,7 +15706,10 @@ var harnessInstallationStateSchema = external_exports.object({
|
|
|
15706
15706
|
latestVersion: external_exports.string().min(1).max(128),
|
|
15707
15707
|
updateAvailable: external_exports.boolean(),
|
|
15708
15708
|
canUpdate: external_exports.boolean(),
|
|
15709
|
-
|
|
15709
|
+
// Adapter-owned diagnostic text; UI uses messageCode rather than displaying it verbatim.
|
|
15710
|
+
message: external_exports.string().max(2048).optional(),
|
|
15711
|
+
messageCode: external_exports.string().min(1).max(128).optional(),
|
|
15712
|
+
latestVersionKind: external_exports.enum(["unknown", "tracking-branch"]).optional()
|
|
15710
15713
|
}).strict();
|
|
15711
15714
|
|
|
15712
15715
|
// ../../shared-contracts/dist/codex-accounts.js
|
|
@@ -16001,7 +16004,7 @@ var updateStatusSchema = external_exports.strictObject({
|
|
|
16001
16004
|
}
|
|
16002
16005
|
});
|
|
16003
16006
|
var updateEmptyParamsSchema = external_exports.strictObject({});
|
|
16004
|
-
var githubReleaseNotesUrlSchema = external_exports.string().max(300).regex(/^https:\/\/github\.com\/LiberSeek\/BOFT-CLI\/releases\/tag\/v[0-9A-Za-z.+-]+$/u, "release notes URL must identify a codexhost GitHub Release");
|
|
16007
|
+
var githubReleaseNotesUrlSchema = external_exports.string().max(300).regex(/^https:\/\/github\.com\/(LiberSeek|LIBERSEEK)\/BOFT-CLI\/releases\/tag\/v[0-9A-Za-z.+-]+$/u, "release notes URL must identify a codexhost GitHub Release");
|
|
16005
16008
|
var updateCheckResultSchema = external_exports.strictObject({
|
|
16006
16009
|
currentVersion: updateSemanticVersionSchema,
|
|
16007
16010
|
installation: updateInstallationSchema.nullable(),
|