@kynver-app/openclaw-agent-os 0.1.27 → 0.1.29
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/index.js +86 -19
- package/dist/index.js.map +4 -4
- package/package.json +1 -1
- package/scripts/bootstrap-openclaw.mjs +12 -1
package/package.json
CHANGED
|
@@ -1,6 +1,13 @@
|
|
|
1
|
-
#!/usr/bin/env node
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
import { readFileSync } from "node:fs";
|
|
3
|
+
import { dirname, join } from "node:path";
|
|
4
|
+
import { fileURLToPath } from "node:url";
|
|
2
5
|
import { spawnSync } from "node:child_process";
|
|
3
6
|
|
|
7
|
+
const PACKAGE_VERSION = JSON.parse(
|
|
8
|
+
readFileSync(join(dirname(fileURLToPath(import.meta.url)), "..", "package.json"), "utf8"),
|
|
9
|
+
).version;
|
|
10
|
+
|
|
4
11
|
const DEFAULT_PACKAGE = "@kynver-app/openclaw-agent-os@latest";
|
|
5
12
|
const PLUGIN_ID = "kynver-agent-os-tools";
|
|
6
13
|
|
|
@@ -19,6 +26,7 @@ Options:
|
|
|
19
26
|
--skip-restart Do not restart the OpenClaw gateway.
|
|
20
27
|
--dry-run Print and validate the config patch without applying it.
|
|
21
28
|
--help Show this help.
|
|
29
|
+
--version, -v Print this bootstrap script's package version and exit.
|
|
22
30
|
`);
|
|
23
31
|
}
|
|
24
32
|
|
|
@@ -54,6 +62,9 @@ function parseArgs(argv) {
|
|
|
54
62
|
else if (arg === "--help" || arg === "-h") {
|
|
55
63
|
usage();
|
|
56
64
|
process.exit(0);
|
|
65
|
+
} else if (arg === "--version" || arg === "-v") {
|
|
66
|
+
console.log(`kynver-openclaw-agent-os-bootstrap ${PACKAGE_VERSION}`);
|
|
67
|
+
process.exit(0);
|
|
57
68
|
} else {
|
|
58
69
|
throw new Error(`Unknown option: ${arg}`);
|
|
59
70
|
}
|