gm-cc 2.0.419 → 2.0.421
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.
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
"name": "AnEntrypoint"
|
|
5
5
|
},
|
|
6
6
|
"description": "State machine agent with hooks, skills, and automated git enforcement",
|
|
7
|
-
"version": "2.0.
|
|
7
|
+
"version": "2.0.421",
|
|
8
8
|
"metadata": {
|
|
9
9
|
"description": "State machine agent with hooks, skills, and automated git enforcement"
|
|
10
10
|
},
|
package/package.json
CHANGED
package/plugin.json
CHANGED
package/skills/browser/SKILL.md
CHANGED
|
@@ -6,6 +6,9 @@ allowed-tools: Bash(browser:*), Bash(exec:browser*)
|
|
|
6
6
|
|
|
7
7
|
# Browser Automation with playwriter
|
|
8
8
|
|
|
9
|
+
**Use gm subagents for all independent work items. Invoke all skills in the chain: planning → gm-execute → gm-emit → gm-complete → update-docs.**
|
|
10
|
+
|
|
11
|
+
|
|
9
12
|
## Two Pathways
|
|
10
13
|
|
|
11
14
|
**Session commands** (`browser:` prefix) — manage multi-step sessions via playwriter CLI. Each `browser:` block runs its commands sequentially.
|
|
@@ -64,12 +67,6 @@ browser:
|
|
|
64
67
|
playwriter -s 1 -e 'console.log(state.x)'
|
|
65
68
|
```
|
|
66
69
|
|
|
67
|
-
List active sessions:
|
|
68
|
-
|
|
69
|
-
```
|
|
70
|
-
browser:
|
|
71
|
-
playwriter session list
|
|
72
|
-
```
|
|
73
70
|
|
|
74
71
|
**RULE**: The `-e` argument must use single quotes. The JS inside must use double quotes for strings.
|
|
75
72
|
|
|
@@ -135,21 +132,7 @@ task_N
|
|
|
135
132
|
|
|
136
133
|
## Common Patterns
|
|
137
134
|
|
|
138
|
-
### Navigate and check current URL/status
|
|
139
|
-
|
|
140
|
-
```
|
|
141
|
-
exec:browser
|
|
142
|
-
await page.goto('https://example.com')
|
|
143
|
-
console.log('URL:', page.url())
|
|
144
|
-
console.log('title:', await page.title())
|
|
145
|
-
```
|
|
146
|
-
|
|
147
|
-
### Screenshot
|
|
148
135
|
|
|
149
|
-
```
|
|
150
|
-
browser:
|
|
151
|
-
playwriter -s 1 -e 'await screenshotWithAccessibilityLabels({ page })'
|
|
152
|
-
```
|
|
153
136
|
|
|
154
137
|
### Data Extraction
|
|
155
138
|
|
|
@@ -159,18 +142,6 @@ const items = await page.$$eval('.product-title', els => els.map(e => e.textCont
|
|
|
159
142
|
console.log(JSON.stringify(items))
|
|
160
143
|
```
|
|
161
144
|
|
|
162
|
-
### Fetch bypassing browser cache
|
|
163
|
-
|
|
164
|
-
`fetch()` inside `page.evaluate()` hits the browser cache — use `cache: 'no-store'` to get fresh content:
|
|
165
|
-
|
|
166
|
-
```
|
|
167
|
-
exec:browser
|
|
168
|
-
const text = await page.evaluate(async () => {
|
|
169
|
-
const r = await fetch('./app.js', { cache: 'no-store' })
|
|
170
|
-
return await r.text()
|
|
171
|
-
})
|
|
172
|
-
console.log('Has feature:', text.includes('myFunction'))
|
|
173
|
-
```
|
|
174
145
|
|
|
175
146
|
### Console Monitoring — set up listener first, then poll
|
|
176
147
|
|
|
@@ -189,14 +160,6 @@ console.log('logs so far:', JSON.stringify(state.logs.slice(-20)))
|
|
|
189
160
|
console.log('errors:', JSON.stringify(state.errors))
|
|
190
161
|
```
|
|
191
162
|
|
|
192
|
-
### Web Worker Access
|
|
193
|
-
|
|
194
|
-
```
|
|
195
|
-
exec:browser
|
|
196
|
-
const workers = page.workers()
|
|
197
|
-
console.log('Workers:', workers.length, workers.map(w => w.url()).join(', '))
|
|
198
|
-
```
|
|
199
|
-
|
|
200
163
|
```
|
|
201
164
|
exec:browser
|
|
202
165
|
if (page.workers().length > 0) {
|
|
@@ -205,9 +168,6 @@ if (page.workers().length > 0) {
|
|
|
205
168
|
}
|
|
206
169
|
```
|
|
207
170
|
|
|
208
|
-
### Access window globals
|
|
209
|
-
|
|
210
|
-
```
|
|
211
171
|
exec:browser
|
|
212
172
|
const result = await page.evaluate(() => JSON.stringify({
|
|
213
173
|
entityCount: window.debug?.scene?.children?.length,
|
|
@@ -216,9 +176,6 @@ const result = await page.evaluate(() => JSON.stringify({
|
|
|
216
176
|
console.log(result)
|
|
217
177
|
```
|
|
218
178
|
|
|
219
|
-
### Wait for element with short poll
|
|
220
|
-
|
|
221
|
-
```
|
|
222
179
|
exec:browser
|
|
223
180
|
const start = Date.now()
|
|
224
181
|
while (Date.now() - start < 12000) {
|
|
@@ -5,6 +5,9 @@ description: Mandatory codebase search workflow. Use whenever you need to find a
|
|
|
5
5
|
|
|
6
6
|
# CODEBASE SEARCH — Mandatory Workflow
|
|
7
7
|
|
|
8
|
+
**Use gm subagents for all independent work items. Invoke all skills in the chain: planning → gm-execute → gm-emit → gm-complete → update-docs.**
|
|
9
|
+
|
|
10
|
+
|
|
8
11
|
`exec:codesearch` is the only way to search the codebase. Glob, Grep, Find, Explore are hook-blocked.
|
|
9
12
|
|
|
10
13
|
## Syntax
|
|
@@ -5,6 +5,9 @@ description: Create a lang/ plugin that wires any CLI tool or language runtime i
|
|
|
5
5
|
|
|
6
6
|
# CREATE LANG PLUGIN
|
|
7
7
|
|
|
8
|
+
**Use gm subagents for all independent work items. Invoke all skills in the chain: planning → gm-execute → gm-emit → gm-complete → update-docs.**
|
|
9
|
+
|
|
10
|
+
|
|
8
11
|
A lang plugin is a single CommonJS file at `<projectDir>/lang/<id>.js`. gm-cc's hooks auto-discover it — no hook editing, no settings changes. The plugin gets three integration points: **exec dispatch**, **LSP diagnostics**, and **context injection**.
|
|
9
12
|
|
|
10
13
|
## PLUGIN SHAPE
|
package/skills/ssh/SKILL.md
CHANGED
|
@@ -5,6 +5,9 @@ description: Run shell commands on remote SSH hosts via exec:ssh. Reads targets
|
|
|
5
5
|
|
|
6
6
|
# exec:ssh — Remote SSH Execution
|
|
7
7
|
|
|
8
|
+
**Use gm subagents for all independent work items. Invoke all skills in the chain: planning → gm-execute → gm-emit → gm-complete → update-docs.**
|
|
9
|
+
|
|
10
|
+
|
|
8
11
|
Runs shell commands on a remote host over SSH. No shell open, no manual connection — just write the command.
|
|
9
12
|
|
|
10
13
|
## Setup
|