oneie 3.6.27 → 3.6.28

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.
@@ -6,23 +6,85 @@ When user types `/one`, follow this workflow:
6
6
 
7
7
  ---
8
8
 
9
- ## Step 1: Server Status Check (< 1 second)
9
+ ## Step 1: Server Status Check & Auto-Start (< 3 seconds)
10
+
11
+ ### Check if Running
10
12
 
11
13
  ```bash
12
14
  lsof -ti:4321 2>/dev/null && echo "RUNNING" || echo "STOPPED"
13
15
  ```
14
16
 
15
17
  **If RUNNING:**
18
+ - Show "✅ Dev Server: http://localhost:4321" in the interface below
19
+ - Skip to Step 2
20
+
21
+ **If STOPPED:**
22
+
23
+ ### Determine Working Directory
24
+
25
+ ```bash
26
+ pwd | grep -q '/web$' && echo "IN_WEB" || echo "IN_ROOT"
16
27
  ```
17
- ✅ Dev Server: http://localhost:4321
28
+
29
+ ### Check if Dependencies Installed
30
+
31
+ **If IN_ROOT:**
32
+ ```bash
33
+ [ -d web/node_modules ] && echo "installed" || echo "missing"
18
34
  ```
19
35
 
20
- **If STOPPED:**
21
- - Check if installed: `[ -d web/node_modules ] && echo "installed" || echo "missing"`
22
- - If missing: Run `cd web && bun install`
23
- - Then: Run `cd web && bun run dev > /dev/null 2>&1 &`
24
- - Show: "🚀 Starting server..." then wait 2 seconds
25
- - Final: "✅ Dev Server: http://localhost:4321"
36
+ **If IN_WEB:**
37
+ ```bash
38
+ [ -d node_modules ] && echo "installed" || echo "missing"
39
+ ```
40
+
41
+ ### Install if Missing
42
+
43
+ **If missing, show progress and install:**
44
+
45
+ ```
46
+ 📦 Installing dependencies...
47
+ ```
48
+
49
+ **If IN_ROOT:**
50
+ ```bash
51
+ cd web && bun install
52
+ ```
53
+
54
+ **If IN_WEB:**
55
+ ```bash
56
+ bun install
57
+ ```
58
+
59
+ ### Start Server
60
+
61
+ **If IN_ROOT:**
62
+ ```bash
63
+ cd web && bun run dev > /dev/null 2>&1 &
64
+ ```
65
+
66
+ **If IN_WEB:**
67
+ ```bash
68
+ bun run dev > /dev/null 2>&1 &
69
+ ```
70
+
71
+ ### Wait and Verify
72
+
73
+ ```bash
74
+ sleep 3 && lsof -ti:4321 2>/dev/null
75
+ ```
76
+
77
+ ### Open Start Page
78
+
79
+ ```bash
80
+ open http://localhost:4321/start 2>/dev/null || xdg-open http://localhost:4321/start 2>/dev/null || start http://localhost:4321/start 2>/dev/null
81
+ ```
82
+
83
+ **Final Output:**
84
+ ```
85
+ ✅ Dev Server: http://localhost:4321
86
+ 🚀 Opening /start page in browser...
87
+ ```
26
88
 
27
89
  ---
28
90
 
@@ -72,83 +72,95 @@ lsof -ti:4321 2>/dev/null
72
72
  If running, show:
73
73
 
74
74
  ```
75
- ⚠️ Server already running on port 4321
75
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
76
+ ⚠️ Server Already Running
77
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
76
78
 
77
79
  URL: http://localhost:4321
80
+ PID: [process-id]
78
81
 
79
82
  Use /server restart to restart it.
80
- ```
81
83
 
82
- ### Step 2: Verify web Directory Exists
83
-
84
- ```bash
85
- [ -d web ] && echo "exists" || echo "missing"
84
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
86
85
  ```
87
86
 
88
- If missing, show error:
87
+ Stop here and don't continue.
89
88
 
90
- ```
91
- ❌ web/ directory not found
89
+ ### Step 2: Detect Working Directory
92
90
 
93
- Are you in the ONE Platform root directory?
94
-
95
- Current directory: [pwd]
91
+ ```bash
92
+ pwd | grep -q '/web$' && echo "IN_WEB" || echo "IN_ROOT"
96
93
  ```
97
94
 
98
- ### Step 3: Check Dependencies are Installed
99
-
100
- Check if `node_modules` exists in web/:
95
+ ### Step 3: Check Dependencies Installed
101
96
 
97
+ **If IN_ROOT:**
102
98
  ```bash
103
99
  [ -d web/node_modules ] && echo "installed" || echo "missing"
104
100
  ```
105
101
 
106
- **If dependencies not installed:**
102
+ **If IN_WEB:**
103
+ ```bash
104
+ [ -d node_modules ] && echo "installed" || echo "missing"
105
+ ```
107
106
 
108
- Show progress message and install:
107
+ ### Step 4: Install Dependencies if Missing
109
108
 
110
- ```
111
- 📦 Installing dependencies...
109
+ **If missing, show progress:**
112
110
 
113
- Installing:
114
- cd web && bun install
111
+ ```
112
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
113
+ 📦 Installing Dependencies
114
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
115
115
  ```
116
116
 
117
- Run the install:
118
-
117
+ **If IN_ROOT:**
119
118
  ```bash
120
119
  cd web && bun install
121
120
  ```
122
121
 
123
- **If install succeeds, continue to Step 4.**
122
+ **If IN_WEB:**
123
+ ```bash
124
+ bun install
125
+ ```
124
126
 
125
- **If install fails, show error:**
127
+ **If install fails, show error and STOP:**
126
128
 
127
129
  ```
128
- ❌ Failed to install dependencies
130
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
131
+ ❌ Failed to Install Dependencies
132
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
129
133
 
130
134
  Try manually:
131
- cd web && bun install
135
+ bun install
132
136
 
133
137
  Common issues:
134
- • Node.js/Bun not installed
138
+ • Bun not installed (curl -fsSL https://bun.sh/install | bash)
135
139
  • package.json corrupted
136
140
  • Network issues
141
+
142
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
137
143
  ```
138
144
 
139
- ### Step 4: Start Server in Background
145
+ ### Step 5: Start Server in Background
140
146
 
147
+ **If IN_ROOT:**
141
148
  ```bash
142
149
  cd web && bun run dev > /dev/null 2>&1 &
143
150
  ```
144
151
 
145
- ### Step 5: Wait and Verify (2 seconds)
152
+ **If IN_WEB:**
153
+ ```bash
154
+ bun run dev > /dev/null 2>&1 &
155
+ ```
156
+
157
+ ### Step 6: Wait and Verify (3 seconds)
146
158
 
147
159
  ```bash
148
- sleep 2 && lsof -ti:4321 2>/dev/null
160
+ sleep 3 && lsof -ti:4321 2>/dev/null
149
161
  ```
150
162
 
151
- ### Step 5: Open Start Page in Browser
163
+ ### Step 7: Open Start Page in Browser
152
164
 
153
165
  ```bash
154
166
  open http://localhost:4321/start 2>/dev/null || xdg-open http://localhost:4321/start 2>/dev/null || start http://localhost:4321/start 2>/dev/null
@@ -164,7 +176,7 @@ open http://localhost:4321/start 2>/dev/null || xdg-open http://localhost:4321/s
164
176
  URL: http://localhost:4321/start
165
177
  PID: [process-id]
166
178
 
167
- Opening start page in your browser...
179
+ Opening /start page in your browser...
168
180
 
169
181
  The server is running in the background.
170
182
 
@@ -179,15 +191,19 @@ Commands:
179
191
  **If failed to start:**
180
192
 
181
193
  ```
182
- ❌ Failed to start dev server
194
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
195
+ ❌ Failed to Start Dev Server
196
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
183
197
 
184
198
  Check for errors:
185
- cd web && bun run dev
199
+ bun run dev
186
200
 
187
201
  Possible issues:
188
- • Port 4321 already in use
202
+ • Port 4321 in use (try: lsof -ti:4321 | xargs kill)
189
203
  • Missing dependencies (run: bun install)
190
- • Build errors in web/
204
+ • Build errors (check TypeScript)
205
+
206
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
191
207
  ```
192
208
 
193
209
  ---
@@ -257,34 +273,63 @@ lsof -ti:4321 | xargs kill 2>/dev/null
257
273
  sleep 1
258
274
  ```
259
275
 
260
- ### Step 2: Check Dependencies are Installed
276
+ ### Step 2: Detect Working Directory
277
+
278
+ ```bash
279
+ pwd | grep -q '/web$' && echo "IN_WEB" || echo "IN_ROOT"
280
+ ```
261
281
 
262
- Check if `node_modules` exists in web/:
282
+ ### Step 3: Check Dependencies Installed
263
283
 
284
+ **If IN_ROOT:**
264
285
  ```bash
265
286
  [ -d web/node_modules ] && echo "installed" || echo "missing"
266
287
  ```
267
288
 
268
- **If dependencies not installed, run:**
289
+ **If IN_WEB:**
290
+ ```bash
291
+ [ -d node_modules ] && echo "installed" || echo "missing"
292
+ ```
293
+
294
+ ### Step 4: Install Dependencies if Missing
295
+
296
+ **If missing:**
297
+
298
+ ```
299
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
300
+ 📦 Installing Dependencies
301
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
302
+ ```
269
303
 
304
+ **If IN_ROOT:**
270
305
  ```bash
271
306
  cd web && bun install
272
307
  ```
273
308
 
274
- ### Step 3: Start Server
309
+ **If IN_WEB:**
310
+ ```bash
311
+ bun install
312
+ ```
275
313
 
314
+ ### Step 5: Start Server
315
+
316
+ **If IN_ROOT:**
276
317
  ```bash
277
318
  cd web && bun run dev > /dev/null 2>&1 &
278
- sleep 2
279
319
  ```
280
320
 
281
- ### Step 4: Verify Running
321
+ **If IN_WEB:**
322
+ ```bash
323
+ bun run dev > /dev/null 2>&1 &
324
+ ```
325
+
326
+ ### Step 6: Wait and Verify (3 seconds)
282
327
 
283
328
  ```bash
284
- lsof -ti:4321 2>/dev/null
329
+ sleep 3 && lsof -ti:4321 2>/dev/null
285
330
  ```
286
331
 
287
- ### Step 4: Open Start Page in Browser
332
+ ### Step 7: Open Start Page in Browser
288
333
 
289
334
  ```bash
290
335
  open http://localhost:4321/start 2>/dev/null || xdg-open http://localhost:4321/start 2>/dev/null || start http://localhost:4321/start 2>/dev/null
@@ -301,7 +346,7 @@ URL: http://localhost:4321/start
301
346
  PID: [process-id]
302
347
 
303
348
  Fresh server instance running.
304
- Opening start page in your browser...
349
+ Opening /start page in your browser...
305
350
 
306
351
  ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
307
352
  ```
@@ -309,14 +354,18 @@ Opening start page in your browser...
309
354
  **If restart failed:**
310
355
 
311
356
  ```
312
- ❌ Failed to restart server
357
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
358
+ ❌ Failed to Restart Server
359
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
313
360
 
314
361
  Try manually:
315
362
  1. /server stop
316
363
  2. /server start
317
364
 
318
365
  Or check logs:
319
- cd web && bun run dev
366
+ bun run dev
367
+
368
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
320
369
  ```
321
370
 
322
371
  ---
@@ -0,0 +1,182 @@
1
+ # /start - Quick Server Start
2
+
3
+ ## Instructions for Claude
4
+
5
+ When user types `/start`, quickly start the development server and open the /start page.
6
+
7
+ **This is a simplified command that:**
8
+ 1. Checks if server is running → if yes, just open /start page
9
+ 2. If not running, check if installed → if not, install
10
+ 3. Start the server
11
+ 4. Open /start page in browser
12
+
13
+ ---
14
+
15
+ ## Workflow
16
+
17
+ ### Step 1: Check if Running
18
+
19
+ ```bash
20
+ lsof -ti:4321 2>/dev/null
21
+ ```
22
+
23
+ **If running (PID returned):**
24
+ - Skip to Step 5 (just open /start page)
25
+
26
+ **If not running:**
27
+ - Continue to Step 2
28
+
29
+ ---
30
+
31
+ ### Step 2: Detect Working Directory
32
+
33
+ ```bash
34
+ pwd | grep -q '/web$' && echo "IN_WEB" || echo "IN_ROOT"
35
+ ```
36
+
37
+ ---
38
+
39
+ ### Step 3: Check Dependencies & Install if Needed
40
+
41
+ **If IN_ROOT:**
42
+ ```bash
43
+ [ -d web/node_modules ] && echo "installed" || echo "missing"
44
+ ```
45
+
46
+ **If IN_WEB:**
47
+ ```bash
48
+ [ -d node_modules ] && echo "installed" || echo "missing"
49
+ ```
50
+
51
+ **If missing, show progress and install:**
52
+
53
+ ```
54
+ 📦 Installing dependencies...
55
+ ```
56
+
57
+ **If IN_ROOT:**
58
+ ```bash
59
+ cd web && bun install
60
+ ```
61
+
62
+ **If IN_WEB:**
63
+ ```bash
64
+ bun install
65
+ ```
66
+
67
+ ---
68
+
69
+ ### Step 4: Start Server in Background
70
+
71
+ **If IN_ROOT:**
72
+ ```bash
73
+ cd web && bun run dev > /dev/null 2>&1 &
74
+ ```
75
+
76
+ **If IN_WEB:**
77
+ ```bash
78
+ bun run dev > /dev/null 2>&1 &
79
+ ```
80
+
81
+ **Wait for server to start:**
82
+ ```bash
83
+ sleep 3 && lsof -ti:4321 2>/dev/null
84
+ ```
85
+
86
+ ---
87
+
88
+ ### Step 5: Open /start Page
89
+
90
+ ```bash
91
+ open http://localhost:4321/start 2>/dev/null || xdg-open http://localhost:4321/start 2>/dev/null || start http://localhost:4321/start 2>/dev/null
92
+ ```
93
+
94
+ ---
95
+
96
+ ### Final Output
97
+
98
+ **If server was already running:**
99
+
100
+ ```
101
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
102
+ ✅ Server Already Running
103
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
104
+
105
+ URL: http://localhost:4321/start
106
+ PID: [process-id]
107
+
108
+ Opening /start page in browser...
109
+
110
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
111
+ ```
112
+
113
+ **If server was started:**
114
+
115
+ ```
116
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
117
+ 🚀 Server Started!
118
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
119
+
120
+ URL: http://localhost:4321/start
121
+ PID: [process-id]
122
+
123
+ Opening /start page in browser...
124
+
125
+ The server is running in the background.
126
+
127
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
128
+ ```
129
+
130
+ **If dependencies were installed:**
131
+
132
+ ```
133
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
134
+ 🚀 Server Started!
135
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
136
+
137
+ Dependencies installed: ✅
138
+ URL: http://localhost:4321/start
139
+ PID: [process-id]
140
+
141
+ Opening /start page in browser...
142
+
143
+ The server is running in the background.
144
+
145
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
146
+ ```
147
+
148
+ **If failed:**
149
+
150
+ ```
151
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
152
+ ❌ Failed to Start Server
153
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
154
+
155
+ Try:
156
+ • Check if bun is installed: bun --version
157
+ • Install dependencies: bun install
158
+ • Start manually: bun run dev
159
+ • Check for port conflicts: lsof -ti:4321
160
+
161
+ ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
162
+ ```
163
+
164
+ ---
165
+
166
+ ## Key Principles
167
+
168
+ 1. **FAST** - No unnecessary steps, get server running ASAP
169
+ 2. **SMART** - Detect directory, install only if needed
170
+ 3. **SILENT** - Run server in background
171
+ 4. **HELPFUL** - Always open /start page when done
172
+ 5. **RELIABLE** - Check status before/after actions
173
+
174
+ ---
175
+
176
+ ## Related Commands
177
+
178
+ - `/one` - Full ONE Platform control center with server management
179
+ - `/server start` - Detailed server start with full output
180
+ - `/server stop` - Stop the server
181
+ - `/server restart` - Restart the server
182
+ - `/server status` - Check server status