@clawling/clawchat-plugin-openclaw 2026.7.8-5 → 2026.7.9-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/dist/src/liveware-cli.js +3 -4
- package/package.json +1 -1
- package/src/liveware-cli.ts +4 -5
package/dist/src/liveware-cli.js
CHANGED
|
@@ -5,18 +5,18 @@ export const LIVEWARE_BASE_URL = "https://media.clawling.chat/liveware/";
|
|
|
5
5
|
// A non-default User-Agent is required: the CDN (Cloudflare) returns 403 for
|
|
6
6
|
// known scripting/default UAs, so download requests must identify themselves.
|
|
7
7
|
const LIVEWARE_USER_AGENT = "clawchat-liveware-installer";
|
|
8
|
-
/** Directory where the downloaded
|
|
8
|
+
/** Directory where the downloaded binary lives: <stateDir>/clawchat/liveware. */
|
|
9
9
|
export function livewareDir(stateDir) {
|
|
10
10
|
const root = stateDir ?? resolveStateDir();
|
|
11
11
|
return path.join(root, "clawchat", "liveware");
|
|
12
12
|
}
|
|
13
|
-
/** Map host platform/arch to the
|
|
13
|
+
/** Map host platform/arch to the liveware asset filename, or null if unsupported. */
|
|
14
14
|
export function platformAssets(plat = process.platform, arch = process.arch) {
|
|
15
15
|
const os = plat === "darwin" ? "darwin" : plat === "linux" ? "linux" : null;
|
|
16
16
|
const cpu = arch === "x64" ? "amd64" : arch === "arm64" ? "arm64" : null;
|
|
17
17
|
if (!os || !cpu)
|
|
18
18
|
return null;
|
|
19
|
-
return { liveware: `liveware-${os}-${cpu}
|
|
19
|
+
return { liveware: `liveware-${os}-${cpu}` };
|
|
20
20
|
}
|
|
21
21
|
function findOnPath(name) {
|
|
22
22
|
const raw = process.env.PATH ?? "";
|
|
@@ -84,7 +84,6 @@ export async function ensureLivewareCli(opts = {}) {
|
|
|
84
84
|
}
|
|
85
85
|
await fs.promises.mkdir(dir, { recursive: true });
|
|
86
86
|
await downloadTo(LIVEWARE_BASE_URL + assets.liveware, path.join(dir, "liveware"));
|
|
87
|
-
await downloadTo(LIVEWARE_BASE_URL + assets.tunneAgent, path.join(dir, "tunnel-agent"));
|
|
88
87
|
log?.debug?.(`clawchat-plugin-openclaw: liveware CLI downloaded to ${dir}`);
|
|
89
88
|
}
|
|
90
89
|
catch (err) {
|
package/package.json
CHANGED
package/src/liveware-cli.ts
CHANGED
|
@@ -14,21 +14,21 @@ export type LivewareLogger = {
|
|
|
14
14
|
error?: (m: string) => void;
|
|
15
15
|
};
|
|
16
16
|
|
|
17
|
-
/** Directory where the downloaded
|
|
17
|
+
/** Directory where the downloaded binary lives: <stateDir>/clawchat/liveware. */
|
|
18
18
|
export function livewareDir(stateDir?: string): string {
|
|
19
19
|
const root = stateDir ?? resolveStateDir();
|
|
20
20
|
return path.join(root, "clawchat", "liveware");
|
|
21
21
|
}
|
|
22
22
|
|
|
23
|
-
/** Map host platform/arch to the
|
|
23
|
+
/** Map host platform/arch to the liveware asset filename, or null if unsupported. */
|
|
24
24
|
export function platformAssets(
|
|
25
25
|
plat: string = process.platform,
|
|
26
26
|
arch: string = process.arch,
|
|
27
|
-
): { liveware: string
|
|
27
|
+
): { liveware: string } | null {
|
|
28
28
|
const os = plat === "darwin" ? "darwin" : plat === "linux" ? "linux" : null;
|
|
29
29
|
const cpu = arch === "x64" ? "amd64" : arch === "arm64" ? "arm64" : null;
|
|
30
30
|
if (!os || !cpu) return null;
|
|
31
|
-
return { liveware: `liveware-${os}-${cpu}
|
|
31
|
+
return { liveware: `liveware-${os}-${cpu}` };
|
|
32
32
|
}
|
|
33
33
|
|
|
34
34
|
function findOnPath(name: string): string | null {
|
|
@@ -98,7 +98,6 @@ export async function ensureLivewareCli(
|
|
|
98
98
|
|
|
99
99
|
await fs.promises.mkdir(dir, { recursive: true });
|
|
100
100
|
await downloadTo(LIVEWARE_BASE_URL + assets.liveware, path.join(dir, "liveware"));
|
|
101
|
-
await downloadTo(LIVEWARE_BASE_URL + assets.tunneAgent, path.join(dir, "tunnel-agent"));
|
|
102
101
|
log?.debug?.(`clawchat-plugin-openclaw: liveware CLI downloaded to ${dir}`);
|
|
103
102
|
} catch (err) {
|
|
104
103
|
log?.warn?.(`clawchat-plugin-openclaw: liveware CLI download skipped: ${String(err)}`);
|