@liberseek/boft-cli 0.8.6 → 0.8.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 +33 -4
- package/bin/boft.js +34 -9
- package/bin/codexhost.js +34 -9
- package/package.json +7 -7
package/README.md
CHANGED
|
@@ -5,24 +5,53 @@ BOFT CLI runs Pi and other external harnesses inside Codex Desktop.
|
|
|
5
5
|
## Install
|
|
6
6
|
|
|
7
7
|
```bash
|
|
8
|
-
npm install -g @liberseek/boft-cli@0.8.
|
|
8
|
+
npm install -g @liberseek/boft-cli@0.8.8
|
|
9
9
|
```
|
|
10
10
|
|
|
11
|
-
npm automatically installs the matching macOS, Windows, or Linux platform package. Node.js 22.19.0 or later, except 23.x
|
|
11
|
+
npm automatically installs the matching macOS, Windows, or Linux platform package. Node.js 22.19.0 or later, except 23.x is required. Official ChatGPT/Codex Desktop is only required for the Desktop interface; Web is included and works without it.
|
|
12
12
|
|
|
13
13
|
## Usage
|
|
14
14
|
|
|
15
15
|
```bash
|
|
16
16
|
boft --version
|
|
17
17
|
boft
|
|
18
|
+
boft web
|
|
19
|
+
boft status
|
|
20
|
+
boft autostart on
|
|
21
|
+
boft autostart status
|
|
22
|
+
boft stop
|
|
18
23
|
boft remote install
|
|
19
24
|
boft remote status
|
|
20
25
|
```
|
|
21
26
|
|
|
22
|
-
The `boft` command starts Codex Desktop
|
|
27
|
+
The `boft` command starts Codex Desktop and background Web; without Desktop installed it opens Web instead. On macOS and Linux it returns immediately while the packaged Launcher keeps supervising in the background. On Windows, the command remains attached until Codex Desktop exits so shells that clean up process trees of completed commands cannot discard the supervisor. Re-running `boft` attaches to the same controlled instance. `codexhost` remains available as a compatibility alias.
|
|
28
|
+
|
|
29
|
+
`boft web` ensures Host and Web run in the background, prints a local login link and opens a browser. Over SSH or without a graphical session it only prints the link. Closing the terminal, Desktop or browser leaves Host and Web running; the computer must stay awake and connected. `CODEXHOST_WEB_SERVICE=0` disables Web startup alongside `boft`.
|
|
30
|
+
|
|
31
|
+
Web initially listens on `127.0.0.1:4400`. Use the local Connect devices page for LAN access and Tailscale Serve, or run `boft web --host 0.0.0.0 --port 4500`. The options `--host`, `--port`, `--public-url` and `--trusted-proxy` are validated and saved for later starts; an empty value clears an option. Changing them restarts only Web, disconnecting Web terminals but not Host tasks. An occupied port fails without killing its owner or selecting another port. LAN HTTP is unencrypted.
|
|
32
|
+
|
|
33
|
+
Matching services are reused. A different version or installation replaces the running services; replacing Host interrupts tasks without confirmation. `boft status` is read-only and shows Host/Web versions, the token-free Web address, the last Web failure and autostart status. `boft stop` stops managed Desktop, Web, Host, remote services, Broker and Console in that order, reports interrupted Host tasks, and preserves session data and configuration. A Desktop opened independently is not closed. Remote services return when another computer reconnects; interrupted tasks do not resume automatically.
|
|
34
|
+
|
|
35
|
+
Autostart is off by default. `boft autostart on|off|status` manages current-user login startup; it starts Host and Web without opening a browser. Linux requires systemd user services; linger is user-managed. Running `boft` refreshes enabled autostart with the current Node and CLI paths.
|
|
36
|
+
|
|
37
|
+
Office preview components are downloaded from the npm registry on first use on the Web computer, not the phone. No documents are uploaded for conversion. Download failure affects only Office previews; retry after checking the computer's network.
|
|
38
|
+
|
|
39
|
+
## Uninstall or downgrade
|
|
40
|
+
|
|
41
|
+
Before removing this package or switching to a version without background Web support:
|
|
42
|
+
|
|
43
|
+
```bash
|
|
44
|
+
boft stop
|
|
45
|
+
boft autostart off
|
|
46
|
+
npm uninstall -g @liberseek/boft-cli
|
|
47
|
+
```
|
|
48
|
+
|
|
49
|
+
Tailscale Serve configuration remains after stopping or uninstalling. Check `tailscale serve status`; only if the HTTPS 443 root path still points to this Web, remove it with `tailscale serve --https=443 --set-path=/ off` (substitute the actual HTTPS port). This leaves other paths intact. While Web is running, the local Connect devices page can also disable Serve after confirmation.
|
|
50
|
+
|
|
51
|
+
## Notes
|
|
23
52
|
|
|
24
53
|
On macOS, `remote install` installs a current-user Aqua Harness broker so Background SSH Hosts can use native Claude Code login without reading, copying, or unlocking Keychain credentials.
|
|
25
54
|
|
|
26
55
|
If installation used `--omit=optional`, reinstall without that option so npm can select the native package for the current architecture.
|
|
27
56
|
|
|
28
|
-
If startup reports a platform package version mismatch, close Codex Desktop and run the exact reinstall command in the error. This installs both the CLI and its platform package at the same version, replacing stale independently installed payloads. `
|
|
57
|
+
If startup reports a platform package version mismatch, close Codex Desktop and run the exact reinstall command in the error. This installs both the CLI and its platform package at the same version, replacing stale independently installed payloads. `boft --version` reports the CLI package version; startup also validates the platform payload before launching it.
|
package/bin/boft.js
CHANGED
|
@@ -6,7 +6,7 @@ import { homedir } from "node:os";
|
|
|
6
6
|
import path from "node:path";
|
|
7
7
|
import { fileURLToPath } from "node:url";
|
|
8
8
|
|
|
9
|
-
const version = "0.8.
|
|
9
|
+
const version = "0.8.8";
|
|
10
10
|
const minimumNodeVersion = "22.19.0";
|
|
11
11
|
const excludedNodeRange = {"from":"23.0.0","to":"24.0.0"};
|
|
12
12
|
const userArguments = process.argv.slice(2);
|
|
@@ -28,7 +28,7 @@ const userArguments = process.argv.slice(2);
|
|
|
28
28
|
process.exit(1);
|
|
29
29
|
}
|
|
30
30
|
}
|
|
31
|
-
const repositoryUrl = "https://github.com/
|
|
31
|
+
const repositoryUrl = "https://github.com/LIBERSEEK/BOFT-CLI";
|
|
32
32
|
const startupTraceStartedAt = Date.now();
|
|
33
33
|
function startupTrace(stage) {
|
|
34
34
|
if (process.env.CODEXHOST_STARTUP_TRACE !== "1") return;
|
|
@@ -247,8 +247,15 @@ if (userArguments.length === 0) {
|
|
|
247
247
|
launchArguments = ["launch"];
|
|
248
248
|
} else if (userArguments[0] === "launch") {
|
|
249
249
|
launchArguments = userArguments;
|
|
250
|
-
} else if (userArguments[0] === "inspect") {
|
|
250
|
+
} else if (userArguments[0] === "inspect" || userArguments[0] === "status" || userArguments[0] === "autostart") {
|
|
251
251
|
launchArguments = userArguments;
|
|
252
|
+
} else if (userArguments[0] === "web" || userArguments[0] === "stop") {
|
|
253
|
+
launchArguments = [userArguments[0], "--node", process.execPath, "--host-runtime", hostRuntime,
|
|
254
|
+
"--web-runtime", path.join(packageRoot, "app", "web-server.mjs"), ...userArguments.slice(1)];
|
|
255
|
+
} else if (userArguments[0] === "host" && !["info", "--help", "-h", "help"].includes(userArguments[1])) {
|
|
256
|
+
if (userArguments[1] !== "ensure" && userArguments[1] !== "stop") fail("host expects info, ensure or stop");
|
|
257
|
+
launchArguments = ["host", userArguments[1], "--node", process.execPath, "--host-runtime", hostRuntime,
|
|
258
|
+
"--data", updateEnvironment.CODEXHOST_DATA_DIR || path.join(homedir(), ".codexhost"), ...userArguments.slice(2)];
|
|
252
259
|
} else if (userArguments[0] === "console" || userArguments[0] === "update") {
|
|
253
260
|
launchArguments = null;
|
|
254
261
|
consoleArguments = userArguments.slice(1);
|
|
@@ -262,8 +269,12 @@ if (userArguments.length === 0) {
|
|
|
262
269
|
brokerArguments = userArguments.slice(1);
|
|
263
270
|
} else if (
|
|
264
271
|
userArguments[0] === "harness" ||
|
|
272
|
+
userArguments[0] === "host" ||
|
|
273
|
+
userArguments[0] === "project" ||
|
|
265
274
|
userArguments[0] === "delegate" ||
|
|
266
|
-
userArguments[0] === "thread"
|
|
275
|
+
userArguments[0] === "thread" ||
|
|
276
|
+
userArguments[0] === "client" ||
|
|
277
|
+
userArguments[0] === "events"
|
|
267
278
|
) {
|
|
268
279
|
launchArguments = null;
|
|
269
280
|
delegationArguments = userArguments;
|
|
@@ -274,18 +285,27 @@ if (userArguments.length === 0) {
|
|
|
274
285
|
" boft",
|
|
275
286
|
" boft --version",
|
|
276
287
|
" boft inspect",
|
|
288
|
+
" boft web [--host address] [--port port] [--public-url url] [--trusted-proxy addresses] [--relay control-host]",
|
|
289
|
+
" boft stop",
|
|
290
|
+
" boft status",
|
|
291
|
+
" boft autostart on|off|status",
|
|
277
292
|
" boft console",
|
|
278
293
|
" boft update",
|
|
279
294
|
" boft launch [launcher options]",
|
|
280
295
|
" boft remote install|start|stop|status|uninstall",
|
|
281
296
|
" boft broker install|status|stop|uninstall",
|
|
297
|
+
" boft host ensure|stop [--data directory]",
|
|
298
|
+
" boft host info [--refresh true|false]",
|
|
299
|
+
" boft project list [--query text] [--refresh true|false]",
|
|
282
300
|
" boft delegate --help",
|
|
283
301
|
" boft harness inspect ...",
|
|
284
302
|
" boft delegate start ...",
|
|
285
|
-
" boft thread send|cancel|read|wait|list ...",
|
|
303
|
+
" boft thread send|cancel|read|wait|watch|watches|list|file ...",
|
|
304
|
+
" boft client add|list|remove ...",
|
|
305
|
+
" boft events [--after <id>] [--limit <n>] [--follow true|false]",
|
|
286
306
|
"",
|
|
287
307
|
"This npm package uses the current Node.js runtime and the packaged",
|
|
288
|
-
"Rust launcher/shim. Codex Desktop
|
|
308
|
+
"Rust launcher/shim. Without Codex Desktop, boft opens Web.",
|
|
289
309
|
].join("\n"),
|
|
290
310
|
);
|
|
291
311
|
process.exit(0);
|
|
@@ -486,7 +506,8 @@ if (consoleArguments !== null) {
|
|
|
486
506
|
if (finished) return;
|
|
487
507
|
finished = true;
|
|
488
508
|
startupTrace("Launcher finished startup with code " + code);
|
|
489
|
-
|
|
509
|
+
// Flush queued startup output without waiting for the supervising Launcher.
|
|
510
|
+
process.stdout.end((error) => process.exit(error ? code || 1 : code));
|
|
490
511
|
};
|
|
491
512
|
child.stdout.setEncoding("utf8");
|
|
492
513
|
let ready = false;
|
|
@@ -495,14 +516,17 @@ if (consoleArguments !== null) {
|
|
|
495
516
|
child.stdout.on("data", (chunk) => {
|
|
496
517
|
if (ready) return;
|
|
497
518
|
const output = launcherOutput + chunk;
|
|
498
|
-
|
|
519
|
+
const marker = output.indexOf(readyMarker);
|
|
520
|
+
if (marker !== -1) {
|
|
521
|
+
process.stdout.write(output.slice(0, marker));
|
|
499
522
|
ready = true;
|
|
500
523
|
launcherOutput = "";
|
|
501
524
|
startupTrace("received Launcher ready");
|
|
502
525
|
if (!keepLauncherForeground) finish(0);
|
|
503
526
|
return;
|
|
504
527
|
}
|
|
505
|
-
//
|
|
528
|
+
// Retain only a possible split readiness marker; forward service results unchanged.
|
|
529
|
+
process.stdout.write(output.slice(0, Math.max(0, output.length - readyMarker.length + 1)));
|
|
506
530
|
launcherOutput = output.slice(1 - readyMarker.length);
|
|
507
531
|
});
|
|
508
532
|
child.on("error", (error) => {
|
|
@@ -511,6 +535,7 @@ if (consoleArguments !== null) {
|
|
|
511
535
|
});
|
|
512
536
|
child.on("exit", (code, signal) => {
|
|
513
537
|
startupTrace(ready ? "Launcher exited after ready" : "Launcher exited before ready");
|
|
538
|
+
if (!ready) process.stdout.write(launcherOutput);
|
|
514
539
|
if (signal) {
|
|
515
540
|
process.kill(process.pid, signal);
|
|
516
541
|
return;
|
package/bin/codexhost.js
CHANGED
|
@@ -6,7 +6,7 @@ import { homedir } from "node:os";
|
|
|
6
6
|
import path from "node:path";
|
|
7
7
|
import { fileURLToPath } from "node:url";
|
|
8
8
|
|
|
9
|
-
const version = "0.8.
|
|
9
|
+
const version = "0.8.8";
|
|
10
10
|
const minimumNodeVersion = "22.19.0";
|
|
11
11
|
const excludedNodeRange = {"from":"23.0.0","to":"24.0.0"};
|
|
12
12
|
const userArguments = process.argv.slice(2);
|
|
@@ -28,7 +28,7 @@ const userArguments = process.argv.slice(2);
|
|
|
28
28
|
process.exit(1);
|
|
29
29
|
}
|
|
30
30
|
}
|
|
31
|
-
const repositoryUrl = "https://github.com/
|
|
31
|
+
const repositoryUrl = "https://github.com/LIBERSEEK/BOFT-CLI";
|
|
32
32
|
const startupTraceStartedAt = Date.now();
|
|
33
33
|
function startupTrace(stage) {
|
|
34
34
|
if (process.env.CODEXHOST_STARTUP_TRACE !== "1") return;
|
|
@@ -247,8 +247,15 @@ if (userArguments.length === 0) {
|
|
|
247
247
|
launchArguments = ["launch"];
|
|
248
248
|
} else if (userArguments[0] === "launch") {
|
|
249
249
|
launchArguments = userArguments;
|
|
250
|
-
} else if (userArguments[0] === "inspect") {
|
|
250
|
+
} else if (userArguments[0] === "inspect" || userArguments[0] === "status" || userArguments[0] === "autostart") {
|
|
251
251
|
launchArguments = userArguments;
|
|
252
|
+
} else if (userArguments[0] === "web" || userArguments[0] === "stop") {
|
|
253
|
+
launchArguments = [userArguments[0], "--node", process.execPath, "--host-runtime", hostRuntime,
|
|
254
|
+
"--web-runtime", path.join(packageRoot, "app", "web-server.mjs"), ...userArguments.slice(1)];
|
|
255
|
+
} else if (userArguments[0] === "host" && !["info", "--help", "-h", "help"].includes(userArguments[1])) {
|
|
256
|
+
if (userArguments[1] !== "ensure" && userArguments[1] !== "stop") fail("host expects info, ensure or stop");
|
|
257
|
+
launchArguments = ["host", userArguments[1], "--node", process.execPath, "--host-runtime", hostRuntime,
|
|
258
|
+
"--data", updateEnvironment.CODEXHOST_DATA_DIR || path.join(homedir(), ".codexhost"), ...userArguments.slice(2)];
|
|
252
259
|
} else if (userArguments[0] === "console" || userArguments[0] === "update") {
|
|
253
260
|
launchArguments = null;
|
|
254
261
|
consoleArguments = userArguments.slice(1);
|
|
@@ -262,8 +269,12 @@ if (userArguments.length === 0) {
|
|
|
262
269
|
brokerArguments = userArguments.slice(1);
|
|
263
270
|
} else if (
|
|
264
271
|
userArguments[0] === "harness" ||
|
|
272
|
+
userArguments[0] === "host" ||
|
|
273
|
+
userArguments[0] === "project" ||
|
|
265
274
|
userArguments[0] === "delegate" ||
|
|
266
|
-
userArguments[0] === "thread"
|
|
275
|
+
userArguments[0] === "thread" ||
|
|
276
|
+
userArguments[0] === "client" ||
|
|
277
|
+
userArguments[0] === "events"
|
|
267
278
|
) {
|
|
268
279
|
launchArguments = null;
|
|
269
280
|
delegationArguments = userArguments;
|
|
@@ -274,18 +285,27 @@ if (userArguments.length === 0) {
|
|
|
274
285
|
" boft",
|
|
275
286
|
" boft --version",
|
|
276
287
|
" boft inspect",
|
|
288
|
+
" boft web [--host address] [--port port] [--public-url url] [--trusted-proxy addresses] [--relay control-host]",
|
|
289
|
+
" boft stop",
|
|
290
|
+
" boft status",
|
|
291
|
+
" boft autostart on|off|status",
|
|
277
292
|
" boft console",
|
|
278
293
|
" boft update",
|
|
279
294
|
" boft launch [launcher options]",
|
|
280
295
|
" boft remote install|start|stop|status|uninstall",
|
|
281
296
|
" boft broker install|status|stop|uninstall",
|
|
297
|
+
" boft host ensure|stop [--data directory]",
|
|
298
|
+
" boft host info [--refresh true|false]",
|
|
299
|
+
" boft project list [--query text] [--refresh true|false]",
|
|
282
300
|
" boft delegate --help",
|
|
283
301
|
" boft harness inspect ...",
|
|
284
302
|
" boft delegate start ...",
|
|
285
|
-
" boft thread send|cancel|read|wait|list ...",
|
|
303
|
+
" boft thread send|cancel|read|wait|watch|watches|list|file ...",
|
|
304
|
+
" boft client add|list|remove ...",
|
|
305
|
+
" boft events [--after <id>] [--limit <n>] [--follow true|false]",
|
|
286
306
|
"",
|
|
287
307
|
"This npm package uses the current Node.js runtime and the packaged",
|
|
288
|
-
"Rust launcher/shim. Codex Desktop
|
|
308
|
+
"Rust launcher/shim. Without Codex Desktop, boft opens Web.",
|
|
289
309
|
].join("\n"),
|
|
290
310
|
);
|
|
291
311
|
process.exit(0);
|
|
@@ -486,7 +506,8 @@ if (consoleArguments !== null) {
|
|
|
486
506
|
if (finished) return;
|
|
487
507
|
finished = true;
|
|
488
508
|
startupTrace("Launcher finished startup with code " + code);
|
|
489
|
-
|
|
509
|
+
// Flush queued startup output without waiting for the supervising Launcher.
|
|
510
|
+
process.stdout.end((error) => process.exit(error ? code || 1 : code));
|
|
490
511
|
};
|
|
491
512
|
child.stdout.setEncoding("utf8");
|
|
492
513
|
let ready = false;
|
|
@@ -495,14 +516,17 @@ if (consoleArguments !== null) {
|
|
|
495
516
|
child.stdout.on("data", (chunk) => {
|
|
496
517
|
if (ready) return;
|
|
497
518
|
const output = launcherOutput + chunk;
|
|
498
|
-
|
|
519
|
+
const marker = output.indexOf(readyMarker);
|
|
520
|
+
if (marker !== -1) {
|
|
521
|
+
process.stdout.write(output.slice(0, marker));
|
|
499
522
|
ready = true;
|
|
500
523
|
launcherOutput = "";
|
|
501
524
|
startupTrace("received Launcher ready");
|
|
502
525
|
if (!keepLauncherForeground) finish(0);
|
|
503
526
|
return;
|
|
504
527
|
}
|
|
505
|
-
//
|
|
528
|
+
// Retain only a possible split readiness marker; forward service results unchanged.
|
|
529
|
+
process.stdout.write(output.slice(0, Math.max(0, output.length - readyMarker.length + 1)));
|
|
506
530
|
launcherOutput = output.slice(1 - readyMarker.length);
|
|
507
531
|
});
|
|
508
532
|
child.on("error", (error) => {
|
|
@@ -511,6 +535,7 @@ if (consoleArguments !== null) {
|
|
|
511
535
|
});
|
|
512
536
|
child.on("exit", (code, signal) => {
|
|
513
537
|
startupTrace(ready ? "Launcher exited after ready" : "Launcher exited before ready");
|
|
538
|
+
if (!ready) process.stdout.write(launcherOutput);
|
|
514
539
|
if (signal) {
|
|
515
540
|
process.kill(process.pid, signal);
|
|
516
541
|
return;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@liberseek/boft-cli",
|
|
3
|
-
"version": "0.8.
|
|
3
|
+
"version": "0.8.8",
|
|
4
4
|
"description": "BOFT CLI runs Pi and other external harnesses inside Codex Desktop.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
@@ -15,12 +15,12 @@
|
|
|
15
15
|
"node": ">=22.19.0 <23.0.0 || >=24.0.0"
|
|
16
16
|
},
|
|
17
17
|
"optionalDependencies": {
|
|
18
|
-
"@liberseek/boft-cli-darwin-arm64": "0.8.
|
|
19
|
-
"@liberseek/boft-cli-darwin-x64": "0.8.
|
|
20
|
-
"@liberseek/boft-cli-win32-x64": "0.8.
|
|
21
|
-
"@liberseek/boft-cli-win32-arm64": "0.8.
|
|
22
|
-
"@liberseek/boft-cli-linux-x64": "0.8.
|
|
23
|
-
"@liberseek/boft-cli-linux-arm64": "0.8.
|
|
18
|
+
"@liberseek/boft-cli-darwin-arm64": "0.8.8",
|
|
19
|
+
"@liberseek/boft-cli-darwin-x64": "0.8.8",
|
|
20
|
+
"@liberseek/boft-cli-win32-x64": "0.8.8",
|
|
21
|
+
"@liberseek/boft-cli-win32-arm64": "0.8.8",
|
|
22
|
+
"@liberseek/boft-cli-linux-x64": "0.8.8",
|
|
23
|
+
"@liberseek/boft-cli-linux-arm64": "0.8.8"
|
|
24
24
|
},
|
|
25
25
|
"keywords": [
|
|
26
26
|
"codex",
|