@ssdavidai/zoclaw 1.3.0-next.2 → 1.3.0-next.4

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/bin/zoclaw.js CHANGED
@@ -2,7 +2,9 @@
2
2
  const { execFileSync } = require("child_process");
3
3
  const path = require("path");
4
4
 
5
- const command = process.argv[2];
5
+ const args = process.argv.slice(2);
6
+ const command = args.find((a) => !a.startsWith("-"));
7
+ const flags = args.filter((a) => a.startsWith("-"));
6
8
  const scriptsDir = path.join(__dirname, "..", "scripts");
7
9
 
8
10
  const commands = {
@@ -11,17 +13,24 @@ const commands = {
11
13
  };
12
14
 
13
15
  if (!command || !commands[command]) {
14
- console.log("Usage: zoclaw <command>\n");
16
+ console.log("Usage: zoclaw <command> [options]\n");
15
17
  console.log("Commands:");
16
18
  console.log(" init Full setup (Tailscale + OpenClaw + bootstrap)");
17
19
  console.log(" bootstrap Config patches only (if already installed)");
20
+ console.log("\nOptions:");
21
+ console.log(" --next Use @next (dev) channel for dependencies");
18
22
  process.exit(command ? 1 : 0);
19
23
  }
20
24
 
21
25
  const script = path.join(scriptsDir, commands[command]);
26
+ const env = { ...process.env };
27
+
28
+ if (flags.includes("--next")) {
29
+ env.ZOCLAW_CHANNEL = "next";
30
+ }
22
31
 
23
32
  try {
24
- execFileSync("bash", [script], { stdio: "inherit" });
33
+ execFileSync("bash", [script], { stdio: "inherit", env });
25
34
  } catch (err) {
26
35
  process.exit(err.status ?? 1);
27
36
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ssdavidai/zoclaw",
3
- "version": "1.3.0-next.2",
3
+ "version": "1.3.0-next.4",
4
4
  "description": "Set up OpenClaw on Zo with Tailscale access in one command",
5
5
  "license": "MIT",
6
6
  "repository": {
package/scripts/setup.sh CHANGED
@@ -7,6 +7,7 @@ SECRETS_FILE="${HOME}/.zo_secrets"
7
7
  SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
8
8
  BOOTSTRAP="${SCRIPT_DIR}/bootstrap.sh"
9
9
  USER_SUPERVISOR="/etc/zo/supervisord-user.conf"
10
+ NPM_TAG="${ZOCLAW_CHANNEL:-latest}"
10
11
 
11
12
  # ─── Helpers ──────────────────────────────────────────────────────────
12
13
 
@@ -46,8 +47,8 @@ fi
46
47
 
47
48
  step 2 "Tailscale (zotail)"
48
49
 
49
- echo " Installing zotail..."
50
- npm install -g @ssdavidai/zotail 2>&1 | tail -1
50
+ echo " Installing zotail@${NPM_TAG}..."
51
+ npm install -g "@ssdavidai/zotail@${NPM_TAG}" 2>&1 | tail -1
51
52
 
52
53
  echo " Running zotail setup..."
53
54
  zotail setup