opendevbrowser 0.0.11 → 0.0.12
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/README.md +74 -1
- package/dist/chunk-WTFSMBVH.js +2815 -0
- package/dist/chunk-WTFSMBVH.js.map +1 -0
- package/dist/cli/index.js +1589 -71
- package/dist/cli/index.js.map +1 -1
- package/dist/index.js +164 -2804
- package/dist/index.js.map +1 -1
- package/dist/opendevbrowser.js +164 -2804
- package/dist/opendevbrowser.js.map +1 -1
- package/extension/dist/background.js +121 -0
- package/extension/dist/popup.js +37 -5
- package/extension/dist/relay-settings.js +2 -1
- package/extension/icons/icon128.png +0 -0
- package/extension/icons/icon16.png +0 -0
- package/extension/icons/icon32.png +0 -0
- package/extension/icons/icon48.png +0 -0
- package/extension/manifest.json +1 -1
- package/extension/popup.html +326 -66
- package/package.json +1 -1
- package/skills/AGENTS.md +1 -0
- package/dist/chunk-R5VUZEUU.js +0 -128
- package/dist/chunk-R5VUZEUU.js.map +0 -1
package/README.md
CHANGED
|
@@ -83,6 +83,34 @@ Restart OpenCode, then run `opendevbrowser_status` to verify the plugin is loade
|
|
|
83
83
|
|
|
84
84
|
---
|
|
85
85
|
|
|
86
|
+
### CLI Automation Quick Start
|
|
87
|
+
|
|
88
|
+
Run a local daemon for persistent sessions, then drive automation via CLI commands:
|
|
89
|
+
|
|
90
|
+
```bash
|
|
91
|
+
# Start daemon
|
|
92
|
+
npx opendevbrowser serve
|
|
93
|
+
|
|
94
|
+
# Launch a session
|
|
95
|
+
npx opendevbrowser launch --start-url https://example.com
|
|
96
|
+
|
|
97
|
+
# Capture a snapshot
|
|
98
|
+
npx opendevbrowser snapshot --session-id <session-id>
|
|
99
|
+
|
|
100
|
+
# Interact by ref
|
|
101
|
+
npx opendevbrowser click --session-id <session-id> --ref r12
|
|
102
|
+
```
|
|
103
|
+
|
|
104
|
+
For single-shot scripts:
|
|
105
|
+
|
|
106
|
+
```bash
|
|
107
|
+
npx opendevbrowser run --script ./script.json --output-format json
|
|
108
|
+
```
|
|
109
|
+
|
|
110
|
+
Use `--output-format json|stream-json` for automation-friendly output.
|
|
111
|
+
|
|
112
|
+
---
|
|
113
|
+
|
|
86
114
|
## Features
|
|
87
115
|
|
|
88
116
|
### Browser Control
|
|
@@ -217,7 +245,7 @@ Load a skill: `opendevbrowser_skill_load` with `name` and optional `topic` filte
|
|
|
217
245
|
|
|
218
246
|
The extension enables **Mode C** - attach to existing logged-in browser tabs without launching a new browser.
|
|
219
247
|
|
|
220
|
-
### Auto-Pair
|
|
248
|
+
### Auto-Connect + Auto-Pair
|
|
221
249
|
|
|
222
250
|
The plugin and extension can automatically pair:
|
|
223
251
|
|
|
@@ -226,6 +254,27 @@ The plugin and extension can automatically pair:
|
|
|
226
254
|
3. Extension fetches relay port from discovery, then fetches token from the relay server
|
|
227
255
|
4. Connection established with color indicator (green = connected)
|
|
228
256
|
|
|
257
|
+
**Auto-connect** and **Auto-pair** are enabled by default for a seamless setup. The extension badge shows status (ON/OFF).
|
|
258
|
+
|
|
259
|
+
### Default Settings (Extension)
|
|
260
|
+
|
|
261
|
+
| Setting | Default |
|
|
262
|
+
|---------|---------|
|
|
263
|
+
| Relay port | `8787` |
|
|
264
|
+
| Auto-connect | `true` |
|
|
265
|
+
| Auto-pair | `true` |
|
|
266
|
+
| Require pairing token | `true` |
|
|
267
|
+
| Pairing token | `null` (fetched on connect) |
|
|
268
|
+
|
|
269
|
+
### Connection Flow (Extension Relay)
|
|
270
|
+
|
|
271
|
+
1. Extension checks the discovery endpoint at `http://127.0.0.1:8787/config`.
|
|
272
|
+
2. It learns the relay port and whether pairing is required.
|
|
273
|
+
3. If pairing is required and Auto-pair is on, it fetches the token from `http://127.0.0.1:<relayPort>/pair`.
|
|
274
|
+
4. It connects to `ws://127.0.0.1:<relayPort>/extension` using the extension origin.
|
|
275
|
+
|
|
276
|
+
`/config` and `/pair` are extension-origin only for CSWSH protection.
|
|
277
|
+
|
|
229
278
|
### Manual Setup
|
|
230
279
|
|
|
231
280
|
1. Start OpenCode once so the plugin can extract the extension assets.
|
|
@@ -236,6 +285,15 @@ The plugin and extension can automatically pair:
|
|
|
236
285
|
(if `relayToken` is missing, either add one to `opendevbrowser.jsonc` or use Auto-Pair).
|
|
237
286
|
5. Click Connect
|
|
238
287
|
|
|
288
|
+
### Where Extension Assets Live
|
|
289
|
+
|
|
290
|
+
Extension assets are bundled inside the NPM package and extracted on install/startup:
|
|
291
|
+
|
|
292
|
+
- Primary: `~/.config/opencode/opendevbrowser/extension`
|
|
293
|
+
- Fallback: `~/.cache/opencode/node_modules/opendevbrowser/extension`
|
|
294
|
+
|
|
295
|
+
Extraction is handled by `extractExtension()` (see `src/extension-extractor.ts`).
|
|
296
|
+
|
|
239
297
|
---
|
|
240
298
|
|
|
241
299
|
## Configuration
|
|
@@ -338,6 +396,7 @@ rm -rf ~/.cache/opencode/node_modules/opendevbrowser
|
|
|
338
396
|
npx opendevbrowser --update
|
|
339
397
|
```
|
|
340
398
|
|
|
399
|
+
Architecture overview: [docs/ARCHITECTURE.md](docs/ARCHITECTURE.md)
|
|
341
400
|
Release checklist: [docs/DISTRIBUTION_PLAN.md](docs/DISTRIBUTION_PLAN.md)
|
|
342
401
|
|
|
343
402
|
---
|
|
@@ -354,6 +413,20 @@ npm run version:check # Verify package/extension version alignment
|
|
|
354
413
|
npm run extension:pack # Build extension zip for releases
|
|
355
414
|
```
|
|
356
415
|
|
|
416
|
+
### Packaging & Distribution (NPM + GitHub + Extension)
|
|
417
|
+
|
|
418
|
+
Uniform versioning is required (source of truth: `package.json`):
|
|
419
|
+
|
|
420
|
+
1. Bump `package.json` version.
|
|
421
|
+
2. Run: `npm run extension:sync`
|
|
422
|
+
3. Run: `npm run version:check`
|
|
423
|
+
4. Run: `npm run build`
|
|
424
|
+
5. Run: `npm run extension:build`
|
|
425
|
+
6. Run: `npm run extension:pack` (outputs `./opendevbrowser-extension.zip`)
|
|
426
|
+
7. Publish to NPM and attach the zip to the GitHub release tag (`vX.Y.Z`).
|
|
427
|
+
|
|
428
|
+
Release checklist: `docs/DISTRIBUTION_PLAN.md`
|
|
429
|
+
|
|
357
430
|
---
|
|
358
431
|
|
|
359
432
|
## Privacy
|