@silicaclaw/cli 2026.3.19-22 → 2026.3.19-23

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/CHANGELOG.md CHANGED
@@ -2,6 +2,12 @@
2
2
 
3
3
  ## v1.0 beta - 2026-03-19
4
4
 
5
+ ### 2026.3.19-23
6
+
7
+ - release build:
8
+ - prepared another fresh beta-channel package build without publishing
9
+ - regenerated the npm tarball through the verified release packing workflow
10
+
5
11
  ### 2026.3.19-22
6
12
 
7
13
  - release build:
package/VERSION CHANGED
@@ -1 +1 @@
1
- v2026.3.19-22
1
+ v2026.3.19-23
@@ -1 +1 @@
1
- 2026.3.19-beta.22
1
+ 2026.3.19-beta.23
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "silicaclaw-broadcast",
3
- "version": "2026.3.19-beta.22",
3
+ "version": "2026.3.19-beta.23",
4
4
  "display_name": "SilicaClaw Broadcast",
5
5
  "description": "OpenClaw skill for reading SilicaClaw public broadcasts, publishing public broadcasts, and forwarding relevant updates to the owner through OpenClaw's native social channel.",
6
6
  "entrypoints": {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@silicaclaw/cli",
3
- "version": "2026.3.19-22",
3
+ "version": "2026.3.19-23",
4
4
  "private": false,
5
5
  "publishConfig": {
6
6
  "access": "public"
@@ -148,23 +148,23 @@ function userNpmCacheDir() {
148
148
  return resolve(homedir(), ".silicaclaw", "npm-cache");
149
149
  }
150
150
 
151
- function shimScriptText(channel = "latest") {
151
+ function shimScriptText(specifier = "latest") {
152
152
  return [
153
153
  "#!/usr/bin/env bash",
154
154
  "set -euo pipefail",
155
155
  'export npm_config_cache="${npm_config_cache:-$HOME/.silicaclaw/npm-cache}"',
156
- `exec npx -y @silicaclaw/cli@${channel} "$@"`,
156
+ `exec npx -y @silicaclaw/cli@${specifier} "$@"`,
157
157
  "",
158
158
  ].join("\n");
159
159
  }
160
160
 
161
- function ensureLatestUserShim() {
161
+ function ensureUserShim(specifier = "latest") {
162
162
  const shimPath = userShimPath();
163
163
  const binDir = userShimDir();
164
164
  const npmCacheDir = userNpmCacheDir();
165
165
  mkdirSync(binDir, { recursive: true });
166
166
  mkdirSync(npmCacheDir, { recursive: true });
167
- writeFileSync(shimPath, shimScriptText("latest"), { encoding: "utf8", mode: 0o755 });
167
+ writeFileSync(shimPath, shimScriptText(specifier), { encoding: "utf8", mode: 0o755 });
168
168
  }
169
169
 
170
170
  function ensureLineInFile(filePath, block) {
@@ -231,7 +231,7 @@ function shellInitTargets() {
231
231
  return targets;
232
232
  }
233
233
 
234
- function installPersistentCommand() {
234
+ function installPersistentCommand(specifier = readPackageVersion()) {
235
235
  const binDir = userShimDir();
236
236
  const shimPath = userShimPath();
237
237
  const envFile = userEnvFile();
@@ -251,7 +251,7 @@ function installPersistentCommand() {
251
251
  mkdirSync(binDir, { recursive: true });
252
252
  mkdirSync(npmCacheDir, { recursive: true });
253
253
  writeFileSync(envFile, envBlock, { encoding: "utf8", mode: 0o755 });
254
- writeFileSync(shimPath, shimScriptText("latest"), { encoding: "utf8", mode: 0o755 });
254
+ writeFileSync(shimPath, shimScriptText(specifier || "latest"), { encoding: "utf8", mode: 0o755 });
255
255
  const rcFiles = shellInitTargets();
256
256
  const updatedFiles = [];
257
257
  const configuredFiles = [];
@@ -330,6 +330,32 @@ function showUpdateGuide(current, targetVersion, channel = "latest") {
330
330
  kv("Channel", channel);
331
331
  }
332
332
 
333
+ function preferredTaggedRelease(tags, current) {
334
+ const latest = tags.latest ? String(tags.latest) : "";
335
+ const beta = tags.beta ? String(tags.beta) : "";
336
+ if (latest && beta) {
337
+ return compareVersionTokens(beta, latest) > 0
338
+ ? { version: beta, channel: "beta" }
339
+ : { version: latest, channel: "latest" };
340
+ }
341
+ if (beta) return { version: beta, channel: "beta" };
342
+ if (latest) return { version: latest, channel: "latest" };
343
+ return { version: current, channel: "unknown" };
344
+ }
345
+
346
+ function preferredRegistryRelease(current) {
347
+ try {
348
+ const result = runCapture("npm", ["view", "@silicaclaw/cli", "dist-tags", "--json"]);
349
+ if ((result.status ?? 1) !== 0) return { version: current, channel: "current", tags: null };
350
+ const text = String(result.stdout || "").trim();
351
+ const tags = text ? JSON.parse(text) : {};
352
+ const preferred = preferredTaggedRelease(tags, current);
353
+ return { ...preferred, tags };
354
+ } catch {
355
+ return { version: current, channel: "current", tags: null };
356
+ }
357
+ }
358
+
333
359
  function getGatewayStatus() {
334
360
  try {
335
361
  const result = runCapture("node", [resolve(ROOT_DIR, "scripts", "silicaclaw-gateway.mjs"), "status", "--json"], {
@@ -427,8 +453,8 @@ function tryGlobalUpgrade(version) {
427
453
 
428
454
  const detail = compactOutput(`${exactResult.stdout || ""}\n${exactResult.stderr || ""}`);
429
455
  if (detail.includes("ETARGET") || detail.includes("No matching version found")) {
430
- kv("Fallback", "registry metadata is still settling, retrying via @latest tag");
431
- const fallbackResult = runInherit("npm", ["i", "-g", "@silicaclaw/cli@latest"]);
456
+ kv("Fallback", `registry metadata is still settling, retrying via exact version ${version}`);
457
+ const fallbackResult = runInherit("npm", ["i", "-g", `@silicaclaw/cli@${version}`]);
432
458
  return (fallbackResult.status ?? 1) === 0;
433
459
  }
434
460
 
@@ -442,31 +468,34 @@ function tryGlobalUpgrade(version) {
442
468
  function update() {
443
469
  const current = readPackageVersion();
444
470
  try {
445
- ensureLatestUserShim();
446
- const result = runCapture("npm", ["view", "@silicaclaw/cli", "dist-tags", "--json"]);
447
- if ((result.status ?? 1) !== 0) {
471
+ const registry = preferredRegistryRelease(current);
472
+ if (!registry.tags) {
448
473
  headline();
449
474
  console.log("");
450
475
  console.error(paint("Update check failed", COLOR.bold, COLOR.yellow));
451
- if (result.stderr) console.error(result.stderr.trim());
452
476
  console.log("");
453
477
  kv("Try", "npm view @silicaclaw/cli dist-tags --json");
454
- process.exit(result.status ?? 1);
478
+ process.exit(1);
455
479
  }
456
- const text = String(result.stdout || "").trim();
457
- const tags = text ? JSON.parse(text) : {};
458
- const latest = tags.latest ? String(tags.latest) : "";
459
- showUpdateGuide(current, latest, "latest");
460
- const hasNewLatest = Boolean(latest) && latest !== current;
480
+ const targetVersion = registry.version;
481
+ const targetChannel = registry.channel;
482
+ ensureUserShim(targetVersion || "latest");
483
+ showUpdateGuide(current, targetVersion, targetChannel);
484
+ const latest = registry.tags.latest ? String(registry.tags.latest) : "";
485
+ const beta = registry.tags.beta ? String(registry.tags.beta) : "";
486
+ if (latest && beta && compareVersionTokens(beta, latest) > 0) {
487
+ kv("Registry", `latest tag is older than beta (${latest} < ${beta})`);
488
+ }
489
+ const hasNewTarget = Boolean(targetVersion) && targetVersion !== current;
461
490
  const npxRuntime = isNpxRun();
462
491
 
463
- if (hasNewLatest) {
492
+ if (hasNewTarget) {
464
493
  if (npxRuntime) {
465
- kv("Update", `next run will use ${latest}`);
466
- } else if (tryGlobalUpgrade(latest)) {
467
- kv("Update", `installed ${latest}`);
494
+ kv("Update", `next run will use ${targetVersion}`);
495
+ } else if (tryGlobalUpgrade(targetVersion)) {
496
+ kv("Update", `installed ${targetVersion}`);
468
497
  } else {
469
- kv("Update", `install ${latest} manually if needed`);
498
+ kv("Update", `install ${targetVersion} manually if needed`);
470
499
  }
471
500
  }
472
501
 
@@ -557,7 +586,10 @@ switch (cmd) {
557
586
  update();
558
587
  break;
559
588
  case "install":
560
- installPersistentCommand();
589
+ {
590
+ const preferred = preferredRegistryRelease(readPackageVersion());
591
+ installPersistentCommand(preferred.version || readPackageVersion());
592
+ }
561
593
  break;
562
594
  case "gateway":
563
595
  run("node", [resolve(ROOT_DIR, "scripts", "silicaclaw-gateway.mjs"), ...process.argv.slice(3)], {