gm-copilot-cli 2.0.208 → 2.0.210
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/copilot-profile.md +1 -1
- package/index.html +1 -1
- package/manifest.yml +1 -1
- package/package.json +1 -1
- package/skills/agent-browser/SKILL.md +37 -26
- package/skills/ssh/SKILL.md +86 -0
- package/tools.json +1 -1
package/copilot-profile.md
CHANGED
package/index.html
CHANGED
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
<script type="module">
|
|
19
19
|
import { createElement as h, applyDiff, Fragment } from "webjsx";
|
|
20
20
|
const PLATFORM_NAME="Copilot CLI",PLATFORM_TYPE="CLI Tool",PLATFORM_TYPE_COLOR="#3b82f6";
|
|
21
|
-
const DESCRIPTION="State machine agent with hooks, skills, and automated git enforcement",VERSION="2.0.
|
|
21
|
+
const DESCRIPTION="State machine agent with hooks, skills, and automated git enforcement",VERSION="2.0.210";
|
|
22
22
|
const GITHUB_URL="https://github.com/AnEntrypoint/gm-copilot-cli",BADGE_LABEL="copilot-cli";
|
|
23
23
|
const FEATURES=[{"title":"State Machine","desc":"Immutable PLAN→EXECUTE→EMIT→VERIFY→COMPLETE phases with full mutable tracking"},{"title":"Semantic Search","desc":"Natural language codebase exploration via codesearch skill — no grep needed"},{"title":"Hooks","desc":"Pre-tool, session-start, prompt-submit, and stop hooks for full lifecycle control"},{"title":"Agents","desc":"gm, codesearch, and websearch agents pre-configured and ready to use"},{"title":"MCP Integration","desc":"Model Context Protocol server support built in"},{"title":"Auto-Recovery","desc":"Supervisor hierarchy ensures the system never crashes"}],INSTALL_STEPS=[{"desc":"Install via GitHub CLI","cmd":"gh extension install AnEntrypoint/gm-copilot-cli"},{"desc":"Restart your terminal — activates automatically"}];
|
|
24
24
|
const CURRENT_PLATFORM="gm-copilot-cli";
|
package/manifest.yml
CHANGED
package/package.json
CHANGED
|
@@ -1,11 +1,19 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: agent-browser
|
|
3
3
|
description: Browser automation CLI for AI agents. Use when the user needs to interact with websites, including navigating pages, filling forms, clicking buttons, taking screenshots, extracting data, testing web apps, or automating any browser task. Triggers include requests to "open a website", "fill out a form", "click a button", "take a screenshot", "scrape data from a page", "test this web app", "login to a site", "automate browser actions", or any task requiring programmatic web interaction.
|
|
4
|
-
allowed-tools: Bash(agent-browser
|
|
4
|
+
allowed-tools: agent-browser, Bash(exec:agent-browser*)
|
|
5
5
|
---
|
|
6
6
|
|
|
7
7
|
# Browser Automation with agent-browser
|
|
8
8
|
|
|
9
|
+
## Two Pathways
|
|
10
|
+
|
|
11
|
+
**Ordinary browser control** — call the `agent-browser` tool directly. This covers all standard browser tasks: navigating, clicking, filling forms, taking screenshots, extracting text. The tool accepts CLI-style commands as its input.
|
|
12
|
+
|
|
13
|
+
**JavaScript eval** — use `exec:agent-browser` via Bash when you need to run arbitrary JavaScript in the page context. The code body is piped directly to `agent-browser eval --stdin`. Use this for DOM inspection, custom extraction logic, or anything the CLI commands don't cover.
|
|
14
|
+
|
|
15
|
+
Use the ordinary pathway by default. Switch to eval only when you need JavaScript access to the page.
|
|
16
|
+
|
|
9
17
|
## Core Workflow
|
|
10
18
|
|
|
11
19
|
Every browser automation follows this pattern:
|
|
@@ -202,34 +210,27 @@ agent-browser find placeholder "Search" type "query"
|
|
|
202
210
|
agent-browser find testid "submit-btn" click
|
|
203
211
|
```
|
|
204
212
|
|
|
205
|
-
## JavaScript Evaluation (
|
|
213
|
+
## JavaScript Evaluation (exec pathway)
|
|
206
214
|
|
|
207
|
-
Use
|
|
215
|
+
Use this pathway when you need to run JavaScript in the browser context — not ordinary CLI commands. This goes through `exec:agent-browser` via Bash, which pipes your code to `agent-browser eval --stdin`. **Shell quoting can corrupt complex expressions** — use the heredoc form.
|
|
208
216
|
|
|
209
|
-
|
|
210
|
-
# Simple expressions work with regular quoting
|
|
211
|
-
agent-browser eval 'document.title'
|
|
212
|
-
agent-browser eval 'document.querySelectorAll("img").length'
|
|
217
|
+
Use `exec:agent-browser` via Bash. The code body is piped directly to `agent-browser eval --stdin` — no shell, no escaping.
|
|
213
218
|
|
|
214
|
-
|
|
215
|
-
agent-browser
|
|
219
|
+
```
|
|
220
|
+
exec:agent-browser
|
|
221
|
+
document.title
|
|
222
|
+
```
|
|
223
|
+
|
|
224
|
+
```
|
|
225
|
+
exec:agent-browser
|
|
216
226
|
JSON.stringify(
|
|
217
227
|
Array.from(document.querySelectorAll("img"))
|
|
218
228
|
.filter(i => !i.alt)
|
|
219
229
|
.map(i => ({ src: i.src.split("/").pop(), width: i.width }))
|
|
220
230
|
)
|
|
221
|
-
EVALEOF
|
|
222
|
-
|
|
223
|
-
# Alternative: base64 encoding (avoids all shell escaping issues)
|
|
224
|
-
agent-browser eval -b "$(echo -n 'Array.from(document.querySelectorAll("a")).map(a => a.href)' | base64)"
|
|
225
231
|
```
|
|
226
232
|
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
**Rules of thumb:**
|
|
230
|
-
- Single-line, no nested quotes -> regular `eval 'expression'` with single quotes is fine
|
|
231
|
-
- Nested quotes, arrow functions, template literals, or multiline -> use `eval --stdin <<'EVALEOF'`
|
|
232
|
-
- Programmatic/generated scripts -> use `eval -b` with base64
|
|
233
|
+
Never base64-encode the code. Never add `agent-browser eval` flags. Write plain JavaScript directly as the exec body.
|
|
233
234
|
|
|
234
235
|
## Complete Command Reference
|
|
235
236
|
|
|
@@ -348,12 +349,12 @@ agent-browser wait --load networkidle # Wait for load state (load, domcontentloa
|
|
|
348
349
|
agent-browser wait --fn "window.ready === true" # Wait for JS condition
|
|
349
350
|
```
|
|
350
351
|
|
|
351
|
-
### JavaScript Evaluation
|
|
352
|
-
```
|
|
353
|
-
agent-browser
|
|
354
|
-
|
|
355
|
-
agent-browser eval --stdin <<'EOF' # JS from stdin (heredoc, recommended for complex code)
|
|
352
|
+
### JavaScript Evaluation (exec pathway — not a direct tool command)
|
|
353
|
+
```
|
|
354
|
+
exec:agent-browser
|
|
355
|
+
<plain JS>
|
|
356
356
|
```
|
|
357
|
+
Use `exec:agent-browser` via Bash. Code is piped to `agent-browser eval --stdin`. No base64, no flags.
|
|
357
358
|
|
|
358
359
|
### Browser Environment
|
|
359
360
|
```bash
|
|
@@ -499,7 +500,11 @@ agent-browser -p ios close # Close simulator
|
|
|
499
500
|
|
|
500
501
|
**Always use agent-browser instead of puppeteer, playwright, or playwright-core** — it has the same capabilities with simpler syntax and better integration with AI agents.
|
|
501
502
|
|
|
502
|
-
**
|
|
503
|
+
**Which pathway to use**:
|
|
504
|
+
- Ordinary browser control (navigation, clicking, forms, screenshots) → call the `agent-browser` tool directly
|
|
505
|
+
- Need to run JavaScript in the page → use `exec:agent-browser` via Bash with plain JS as the body
|
|
506
|
+
|
|
507
|
+
**Multi-step workflows** (ordinary pathway — direct tool calls):
|
|
503
508
|
1. `agent-browser open <url>`
|
|
504
509
|
2. `agent-browser snapshot -i` (get refs)
|
|
505
510
|
3. `agent-browser fill @e1 "value"`
|
|
@@ -507,6 +512,12 @@ agent-browser -p ios close # Close simulator
|
|
|
507
512
|
5. `agent-browser wait --load networkidle` (after navigation)
|
|
508
513
|
6. `agent-browser snapshot -i` (re-snapshot for new refs)
|
|
509
514
|
|
|
515
|
+
**JavaScript inspection** (exec pathway — when you need page access):
|
|
516
|
+
```
|
|
517
|
+
exec:agent-browser
|
|
518
|
+
document.title
|
|
519
|
+
```
|
|
520
|
+
|
|
510
521
|
**Debugging complex interactions**: Use `agent-browser --headed open <url>` to see visual browser, then `agent-browser highlight @e1` to verify element targeting.
|
|
511
522
|
|
|
512
|
-
**Ground truth verification**:
|
|
523
|
+
**Ground truth verification**: Use the ordinary pathway (`agent-browser screenshot`) for visual confirmation; use the exec pathway for JavaScript-level inspection.
|
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: ssh
|
|
3
|
+
description: Run shell commands on remote SSH hosts via exec:ssh. Reads targets from ~/.claude/ssh-targets.json. Use for deploying, monitoring, or controlling remote machines.
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# exec:ssh — Remote SSH Execution
|
|
7
|
+
|
|
8
|
+
Runs shell commands on a remote host over SSH. No shell open, no manual connection — just write the command.
|
|
9
|
+
|
|
10
|
+
## Setup
|
|
11
|
+
|
|
12
|
+
Create `~/.claude/ssh-targets.json`:
|
|
13
|
+
|
|
14
|
+
```json
|
|
15
|
+
{
|
|
16
|
+
"default": {
|
|
17
|
+
"host": "192.168.1.10",
|
|
18
|
+
"port": 22,
|
|
19
|
+
"username": "pi",
|
|
20
|
+
"password": "yourpassword"
|
|
21
|
+
},
|
|
22
|
+
"prod": {
|
|
23
|
+
"host": "10.0.0.1",
|
|
24
|
+
"username": "ubuntu",
|
|
25
|
+
"keyPath": "/home/user/.ssh/id_rsa"
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
```
|
|
29
|
+
|
|
30
|
+
Fields: `host` (required), `port` (default 22), `username` (required), `password` OR `keyPath` + optional `passphrase`.
|
|
31
|
+
|
|
32
|
+
## Usage
|
|
33
|
+
|
|
34
|
+
```
|
|
35
|
+
exec:ssh
|
|
36
|
+
<shell command>
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
Target a named host with `@name` on the first line:
|
|
40
|
+
|
|
41
|
+
```
|
|
42
|
+
exec:ssh
|
|
43
|
+
@prod
|
|
44
|
+
sudo systemctl restart myapp
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
Multi-line scripts work:
|
|
48
|
+
|
|
49
|
+
```
|
|
50
|
+
exec:ssh
|
|
51
|
+
cd /var/log && tail -20 syslog
|
|
52
|
+
```
|
|
53
|
+
|
|
54
|
+
## Process Persistence
|
|
55
|
+
|
|
56
|
+
SSH sessions kill child processes on close. To keep a process running after the command returns:
|
|
57
|
+
|
|
58
|
+
```
|
|
59
|
+
exec:ssh
|
|
60
|
+
sudo systemctl reset-failed myunit 2>/dev/null; systemd-run --unit=myunit bash -c 'your-long-running-command'
|
|
61
|
+
```
|
|
62
|
+
|
|
63
|
+
Always call `systemctl reset-failed <unit>` before reusing a unit name, or use a unique timestamped name:
|
|
64
|
+
|
|
65
|
+
```
|
|
66
|
+
exec:ssh
|
|
67
|
+
systemd-run --unit=job-$(date +%s) bash -c 'nohup myprogram &'
|
|
68
|
+
```
|
|
69
|
+
|
|
70
|
+
Fallback if systemd unavailable:
|
|
71
|
+
|
|
72
|
+
```
|
|
73
|
+
exec:ssh
|
|
74
|
+
setsid nohup bash -c 'myprogram > /tmp/out.log 2>&1' &
|
|
75
|
+
```
|
|
76
|
+
|
|
77
|
+
## Dependency
|
|
78
|
+
|
|
79
|
+
Requires `ssh2` npm package. Install in `~/.claude/gm-tools`:
|
|
80
|
+
|
|
81
|
+
```
|
|
82
|
+
exec:bash
|
|
83
|
+
cd ~/.claude/gm-tools && npm install ssh2
|
|
84
|
+
```
|
|
85
|
+
|
|
86
|
+
The plugin searches: `~/.claude/gm-tools/node_modules/ssh2`, `~/.claude/plugins/node_modules/ssh2`, then global.
|