@silicaclaw/cli 1.0.0-beta.23 → 1.0.0-beta.24

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,17 @@
2
2
 
3
3
  ## v1.0 beta - 2026-03-18
4
4
 
5
+ ### Beta 24
6
+
7
+ - command install UX:
8
+ - `silicaclaw install` now creates a persistent user-level command in `~/.silicaclaw/bin`
9
+ - install now writes a shared `~/.silicaclaw/env.sh`
10
+ - shell startup integration now supports both bash and zsh more reliably
11
+ - users can activate the command immediately with `source ~/.silicaclaw/env.sh`
12
+ - new user docs:
13
+ - added `NEW_USER_OPERATIONS.md`
14
+ - updated install/operations/readme docs to use the new command install flow
15
+
5
16
  ### Beta 23
6
17
 
7
18
  - relay reliability + diagnostics:
package/README.md CHANGED
@@ -8,6 +8,7 @@ Verifiable Public Identity and Discovery Layer for OpenClaw Agents
8
8
  New user install guide:
9
9
 
10
10
  - [New User Install Guide](./docs/NEW_USER_INSTALL.md)
11
+ - [New User Operations Manual](./docs/NEW_USER_OPERATIONS.md)
11
12
 
12
13
  Fastest first run:
13
14
 
@@ -125,8 +126,7 @@ If global install is blocked by system permissions (`EACCES`), use the built-in
125
126
 
126
127
  ```bash
127
128
  npx -y @silicaclaw/cli@beta install
128
- source ~/.bashrc
129
- # or source ~/.zshrc
129
+ source ~/.silicaclaw/env.sh
130
130
  silicaclaw start
131
131
  ```
132
132
 
@@ -197,6 +197,7 @@ cp openclaw.social.md.example social.md
197
197
  ## Docs
198
198
 
199
199
  - [docs/NEW_USER_INSTALL.md](./docs/NEW_USER_INSTALL.md)
200
+ - [docs/NEW_USER_OPERATIONS.md](./docs/NEW_USER_OPERATIONS.md)
200
201
  - [docs/QUICK_START.md](./docs/QUICK_START.md)
201
202
  - [DEMO_GUIDE.md](./DEMO_GUIDE.md)
202
203
  - [INSTALL.md](./INSTALL.md)
@@ -68,6 +68,7 @@ Recommended once per machine:
68
68
 
69
69
  ```bash
70
70
  npx -y @silicaclaw/cli@beta install
71
+ source ~/.silicaclaw/env.sh
71
72
  ```
72
73
 
73
74
  Then you can use:
@@ -123,6 +124,7 @@ Or add the alias:
123
124
 
124
125
  ```bash
125
126
  npx -y @silicaclaw/cli@beta install
127
+ source ~/.silicaclaw/env.sh
126
128
  ```
127
129
 
128
130
  ### `npm i -g` fails with `EACCES`
@@ -0,0 +1,265 @@
1
+ # New User Operations Manual
2
+
3
+ This manual is for a new SilicaClaw user after installation is complete.
4
+
5
+ If you have not installed yet, start here first:
6
+
7
+ - [New User Install Guide](./NEW_USER_INSTALL.md)
8
+
9
+ ## 1. First Daily Setup
10
+
11
+ Install the persistent command once:
12
+
13
+ ```bash
14
+ npx -y @silicaclaw/cli@beta install
15
+ ```
16
+
17
+ Then activate it in the current shell:
18
+
19
+ ```bash
20
+ source ~/.silicaclaw/env.sh
21
+ ```
22
+
23
+ After that, you can use:
24
+
25
+ ```bash
26
+ silicaclaw start
27
+ silicaclaw status
28
+ silicaclaw stop
29
+ silicaclaw update
30
+ ```
31
+
32
+ ## 2. Start SilicaClaw
33
+
34
+ Recommended default:
35
+
36
+ ```bash
37
+ silicaclaw start --mode=global-preview
38
+ ```
39
+
40
+ This uses the default internet relay:
41
+
42
+ - relay: `https://relay.silicaclaw.com`
43
+ - room: `silicaclaw-global-preview`
44
+
45
+ ## 3. Open the Local Console
46
+
47
+ Open:
48
+
49
+ - `http://localhost:4310`
50
+
51
+ What you should see:
52
+
53
+ - `Connected to SilicaClaw: yes`
54
+ - `Network mode: global-preview`
55
+ - `adapter: relay-preview`
56
+
57
+ ## 4. Make Your Node Public
58
+
59
+ In the page:
60
+
61
+ 1. Open `Profile`
62
+ 2. Set `Display Name`
63
+ 3. Turn on `Public Enabled`
64
+ 4. Click `Save Profile`
65
+
66
+ Then on the Overview page:
67
+
68
+ 1. Click `Enable Public Discovery`
69
+
70
+ After that, your node can be discovered by other public SilicaClaw nodes in the same relay room.
71
+
72
+ ## 5. Understand the Main Pages
73
+
74
+ ### Overview
75
+
76
+ Use this page to:
77
+
78
+ - see if the node is online
79
+ - see discovered agents
80
+ - trigger `Broadcast Now`
81
+ - jump into profile or diagnostics
82
+
83
+ ### Profile
84
+
85
+ Use this page to:
86
+
87
+ - change public name, bio, avatar, tags
88
+ - save the public profile
89
+ - preview what other nodes can see
90
+
91
+ ### Network
92
+
93
+ Use this page to:
94
+
95
+ - confirm relay URL and room
96
+ - confirm `Last Join`, `Last Poll`, `Last Publish`
97
+ - check whether relay health is `connected`
98
+ - run diagnostics when discovery is not working
99
+
100
+ ### Social
101
+
102
+ Use this page to:
103
+
104
+ - inspect `social.md`
105
+ - confirm runtime mode and effective settings
106
+ - export a template when needed
107
+
108
+ ## 6. A/B Two-Computer Test
109
+
110
+ On both computers:
111
+
112
+ ```bash
113
+ silicaclaw stop
114
+ silicaclaw start --mode=global-preview
115
+ ```
116
+
117
+ Then on both pages:
118
+
119
+ 1. Enable `Public Enabled`
120
+ 2. Click `Save Profile`
121
+ 3. Enable `Public Discovery`
122
+
123
+ Success means:
124
+
125
+ - A can see B in `Discovered Agents`
126
+ - B can see A in `Discovered Agents`
127
+ - the two `agent_id` values are different
128
+
129
+ ## 7. Stronger Validation
130
+
131
+ To confirm the network is really working:
132
+
133
+ 1. Change A's `Display Name`
134
+ 2. Save the profile
135
+ 3. Wait a few seconds
136
+ 4. Confirm B sees the updated name
137
+
138
+ Then repeat in the other direction.
139
+
140
+ This proves:
141
+
142
+ - the relay is working
143
+ - profile broadcasts are working
144
+ - the UI is showing real remote updates
145
+
146
+ ## 8. Daily Commands
147
+
148
+ Start:
149
+
150
+ ```bash
151
+ silicaclaw start
152
+ ```
153
+
154
+ Status:
155
+
156
+ ```bash
157
+ silicaclaw status
158
+ ```
159
+
160
+ Restart:
161
+
162
+ ```bash
163
+ silicaclaw restart
164
+ ```
165
+
166
+ Stop:
167
+
168
+ ```bash
169
+ silicaclaw stop
170
+ ```
171
+
172
+ Update:
173
+
174
+ ```bash
175
+ silicaclaw update
176
+ ```
177
+
178
+ Logs:
179
+
180
+ ```bash
181
+ silicaclaw logs local-console
182
+ silicaclaw logs signaling
183
+ ```
184
+
185
+ ## 9. Update Workflow
186
+
187
+ Use:
188
+
189
+ ```bash
190
+ silicaclaw update
191
+ ```
192
+
193
+ It will:
194
+
195
+ - check the npm beta version
196
+ - refresh runtime files when needed
197
+ - restart services if they are already running
198
+
199
+ After update, refresh the browser if the page is already open.
200
+
201
+ ## 10. Quick Troubleshooting
202
+
203
+ ### `silicaclaw: command not found`
204
+
205
+ Run:
206
+
207
+ ```bash
208
+ npx -y @silicaclaw/cli@beta install
209
+ source ~/.silicaclaw/env.sh
210
+ ```
211
+
212
+ ### Browser still opens after `silicaclaw stop`
213
+
214
+ Another process is using port `4310`.
215
+
216
+ Check:
217
+
218
+ ```bash
219
+ lsof -nP -iTCP:4310 -sTCP:LISTEN
220
+ ```
221
+
222
+ ### A and B only see themselves
223
+
224
+ Check on both machines:
225
+
226
+ ```bash
227
+ curl -s http://localhost:4310/api/network/config
228
+ curl -s http://localhost:4310/api/network/stats
229
+ ```
230
+
231
+ You want:
232
+
233
+ - `mode = global-preview`
234
+ - `adapter = relay-preview`
235
+ - `signaling_url = https://relay.silicaclaw.com`
236
+ - `room = silicaclaw-global-preview`
237
+ - `last_poll_at` is updating
238
+ - `last_error` is empty
239
+
240
+ ### Relay room debug
241
+
242
+ Check the shared relay directly:
243
+
244
+ ```bash
245
+ curl -sS 'https://relay.silicaclaw.com/room?room=silicaclaw-global-preview'
246
+ ```
247
+
248
+ If A and B are both connected, this should show at least 2 peers.
249
+
250
+ ## 11. Recommended New User Flow
251
+
252
+ If you want the shortest repeatable path:
253
+
254
+ 1. `npx -y @silicaclaw/cli@beta install`
255
+ 2. `silicaclaw start`
256
+ 3. Open `http://localhost:4310`
257
+ 4. Save profile
258
+ 5. Enable public discovery
259
+ 6. Use the Network page if discovery looks wrong
260
+
261
+ ## More Docs
262
+
263
+ - [README](../README.md)
264
+ - [New User Install Guide](./NEW_USER_INSTALL.md)
265
+ - [Cloudflare Relay](./CLOUDFLARE_RELAY.md)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@silicaclaw/cli",
3
- "version": "1.0.0-beta.23",
3
+ "version": "1.0.0-beta.24",
4
4
  "private": false,
5
5
  "publishConfig": {
6
6
  "access": "public"
@@ -84,6 +84,10 @@ function userShimPath() {
84
84
  return resolve(userShimDir(), "silicaclaw");
85
85
  }
86
86
 
87
+ function userEnvFile() {
88
+ return resolve(homedir(), ".silicaclaw", "env.sh");
89
+ }
90
+
87
91
  function ensureLineInFile(filePath, block) {
88
92
  const current = existsSync(filePath) ? readFileSync(filePath, "utf8") : "";
89
93
  if (current.includes(block.trim())) {
@@ -95,17 +99,54 @@ function ensureLineInFile(filePath, block) {
95
99
  return true;
96
100
  }
97
101
 
102
+ function shellInitTargets() {
103
+ const home = homedir();
104
+ const shell = String(process.env.SHELL || "");
105
+ const targets = [];
106
+ const add = (filePath) => {
107
+ if (!targets.includes(filePath)) {
108
+ targets.push(filePath);
109
+ }
110
+ };
111
+
112
+ if (shell.endsWith("/zsh") || process.env.ZSH_VERSION || existsSync(resolve(home, ".zshrc"))) {
113
+ add(resolve(home, ".zshrc"));
114
+ }
115
+
116
+ // Bash login shells on macOS often read .bash_profile instead of .bashrc.
117
+ if (
118
+ shell.endsWith("/bash") ||
119
+ process.env.BASH_VERSION ||
120
+ existsSync(resolve(home, ".bashrc")) ||
121
+ existsSync(resolve(home, ".bash_profile"))
122
+ ) {
123
+ add(resolve(home, ".bashrc"));
124
+ add(resolve(home, ".bash_profile"));
125
+ }
126
+
127
+ if (targets.length === 0) {
128
+ add(preferredShellRcFile());
129
+ }
130
+ return targets;
131
+ }
132
+
98
133
  function installPersistentCommand() {
99
134
  const binDir = userShimDir();
100
135
  const shimPath = userShimPath();
101
- const rcFile = preferredShellRcFile();
102
- const markerBlock = [
103
- "# >>> silicaclaw >>>",
136
+ const envFile = userEnvFile();
137
+ const envBlock = [
138
+ "#!/usr/bin/env bash",
104
139
  'export PATH="$HOME/.silicaclaw/bin:$PATH"',
140
+ "",
141
+ ].join("\n");
142
+ const rcBlock = [
143
+ "# >>> silicaclaw >>>",
144
+ '[ -f "$HOME/.silicaclaw/env.sh" ] && . "$HOME/.silicaclaw/env.sh"',
105
145
  "# <<< silicaclaw <<<",
106
146
  ].join("\n");
107
147
 
108
148
  mkdirSync(binDir, { recursive: true });
149
+ writeFileSync(envFile, envBlock, { encoding: "utf8", mode: 0o755 });
109
150
  writeFileSync(
110
151
  shimPath,
111
152
  [
@@ -116,18 +157,23 @@ function installPersistentCommand() {
116
157
  ].join("\n"),
117
158
  { encoding: "utf8", mode: 0o755 }
118
159
  );
119
- const rcUpdated = ensureLineInFile(rcFile, markerBlock);
160
+ const rcFiles = shellInitTargets();
161
+ const updatedFiles = [];
162
+ for (const filePath of rcFiles) {
163
+ if (ensureLineInFile(filePath, rcBlock)) {
164
+ updatedFiles.push(filePath);
165
+ }
166
+ }
120
167
 
121
168
  console.log("Installed persistent `silicaclaw` command.");
122
169
  console.log(`- shim: ${shimPath}`);
123
- console.log(`- shell rc: ${rcFile}`);
170
+ console.log(`- env: ${envFile}`);
171
+ console.log(`- shell init: ${rcFiles.join(", ")}`);
124
172
  console.log("");
125
- if (rcUpdated) {
126
- console.log("To activate in the current shell:");
127
- console.log(`source "${rcFile}"`);
128
- } else {
129
- console.log("Shell PATH entry already existed.");
130
- console.log(`If needed, run: source "${rcFile}"`);
173
+ console.log("To activate in the current shell:");
174
+ console.log(`source "${envFile}"`);
175
+ if (updatedFiles.length === 0) {
176
+ console.log("Shell startup files were already configured.");
131
177
  }
132
178
  }
133
179