gm-cc 2.0.586 → 2.0.588

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.586",
7
+ "version": "2.0.588",
8
8
  "metadata": {
9
9
  "description": "State machine agent with hooks, skills, and automated git enforcement"
10
10
  },
Binary file
Binary file
Binary file
Binary file
Binary file
Binary file
package/bin/plugkit.exe CHANGED
Binary file
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "gm-cc",
3
- "version": "2.0.586",
3
+ "version": "2.0.588",
4
4
  "description": "State machine agent with hooks, skills, and automated git enforcement",
5
5
  "author": "AnEntrypoint",
6
6
  "license": "MIT",
package/plugin.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "gm",
3
- "version": "2.0.586",
3
+ "version": "2.0.588",
4
4
  "description": "State machine agent with hooks, skills, and automated git enforcement",
5
5
  "author": {
6
6
  "name": "AnEntrypoint",
@@ -61,7 +61,7 @@ All work coordination, planning, execution, and verification happens through the
61
61
 
62
62
  All code execution uses `exec:<lang>` via the Bash tool — never direct `Bash(node ...)` or `Bash(npm ...)`.
63
63
 
64
- **Every `git push` is a remote code execution. Watch the triggered GitHub Actions runs immediately `gh run list` to enumerate, `gh run watch <id> --exit-status` per run, `gh run view --log-failed` on failure. Silent pushes are contract violations. Full protocol in `gm-execute`.**
64
+ **Every `git push` triggers GitHub Actions. CI is auto-watched by the Stop hook outcomes (green / failed / still-running) appear in next-turn context. No manual `gh run watch` needed. `gh run view <id> --log-failed` is for on-demand failure diagnosis only. Full behaviour in `gm-execute`.**
65
65
 
66
66
  Do not use `EnterPlanMode`. Do not run code directly via Bash. Invoke `planning` skill first.
67
67
 
@@ -133,38 +133,14 @@ git log origin/main..HEAD --oneline
133
133
  ```
134
134
  Must return empty. If not: stage → commit → push → re-verify. Local commit without push ≠ complete.
135
135
 
136
- ## CI ENFORCEMENT
136
+ ## CI ENFORCEMENT — AUTOMATED
137
137
 
138
- After push, monitor all triggered GitHub Actions runs until they complete:
138
+ The Stop hook automatically watches GitHub Actions runs whose `headSha` matches the just-pushed HEAD. You do not call `gh run list` / `gh run watch` manually.
139
139
 
140
- 1. List runs triggered by the push:
141
- ```
142
- exec:bash
143
- gh run list --limit 5 --json databaseId,name,status,conclusion,headBranch
144
- ```
145
-
146
- 2. For each run that is `in_progress` or `queued`, poll until it completes:
147
- ```
148
- exec:bash
149
- gh run watch <run_id> --exit-status
150
- ```
151
-
152
- 3. If a run fails, view the logs to diagnose:
153
- ```
154
- exec:bash
155
- gh run view <run_id> --log-failed
156
- ```
157
-
158
- 4. Fix the root cause → snake to the appropriate phase (emit for file issues, execute for logic issues, planning for new unknowns) → re-push → re-monitor.
159
-
160
- 5. All runs must reach `conclusion: success` before advancing. A failed CI run is a KNOWN mutable that blocks completion — never ignore it.
161
-
162
- **Cascade awareness**: pushes to this repo may trigger downstream workflows (see AGENTS.md Rust Binary Update Pipeline). After local CI passes, check downstream repos for triggered runs:
163
- ```
164
- exec:bash
165
- gh run list --repo AnEntrypoint/<downstream-repo> --limit 3 --json databaseId,name,status,conclusion
166
- ```
167
- Monitor any cascade runs the same way — poll, diagnose failures, fix if the cause is in this repo.
140
+ - All-green runs Stop approves with a CI summary appended to context for the next turn.
141
+ - Any failed / cancelled / timed-out / action_required run → Stop blocks with the failed run names + IDs in the reason. Treat that as a KNOWN mutable: investigate (`gh run view <id> --log-failed` only when explicitly diagnosing), fix the root cause, regress to the appropriate phase, push again — the hook re-watches automatically.
142
+ - Watch deadline default 180s, override with `GM_CI_WATCH_SECS`. If the deadline passes with runs still in flight, Stop approves with "still in progress" so you do not block on slow Pages-deploy / npm-publish jobs forever.
143
+ - Cascade awareness: if a push to this repo triggers downstream workflows in another repo, those are NOT automatically watched (only same-repo). Manual cascade check stays for those rare cases.
168
144
 
169
145
  ## CODEBASE HYGIENE SWEEP
170
146
 
@@ -85,38 +85,17 @@ exec:runner
85
85
  start|stop|status
86
86
  ```
87
87
 
88
- ## GIT PUSH = CI WATCH — MANDATORY EVERY TIME
88
+ ## GIT PUSH = AUTOMATIC CI WATCH
89
89
 
90
- A `git push` that is not immediately followed by a CI watch is an unwitnessed execution and a violation of this contract. The push triggers GitHub Actions workflows; those workflows are remote execution whose results are ground truth. Every push intermediate commits during EXECUTE, doc pushes during UPDATE-DOCS, every push — triggers this same protocol:
90
+ The Stop hook automatically watches GitHub Actions runs whose `headSha` matches the just-pushed HEAD. Every push is watched without manual `gh run list` / `gh run watch` calls.
91
91
 
92
- 1. Immediately after `git push` succeeds, list the runs the push triggered:
93
- ```
94
- exec:bash
95
- gh run list --limit 5 --json databaseId,name,status,conclusion,headBranch,event,createdAt
96
- ```
97
-
98
- 2. For every run with `status` = `queued` or `in_progress` (from this push), watch until terminal:
99
- ```
100
- exec:bash
101
- gh run watch <run_id> --exit-status
102
- ```
103
-
104
- 3. On failure, inspect logs and decide:
105
- ```
106
- exec:bash
107
- gh run view <run_id> --log-failed
108
- ```
109
- - Caused by your change → regress to the appropriate phase (emit for file issues, execute for logic, planning for new unknowns), fix, re-push, re-watch.
110
- - Pre-existing (not introduced by this session) → document as a known issue in CLAUDE.md with the failing workflow name and reason, then continue. A pre-existing failure is still a KNOWN mutable, just resolved differently.
111
-
112
- 4. Cascade: a push may trigger downstream repo workflows (see AGENTS.md pipeline notes). After local CI reaches terminal state, check downstream:
113
- ```
114
- exec:bash
115
- gh run list --repo AnEntrypoint/<downstream> --limit 3 --json databaseId,name,status,conclusion
116
- ```
117
- Watch and triage the same way.
92
+ - All-green Stop appends a CI summary to its approve reason; you see it in the next turn's context.
93
+ - Any failure → Stop blocks with the failed run names + IDs; treat that as a KNOWN mutable, regress to the right phase, push again — the hook re-watches.
94
+ - Default deadline 180s (override `GM_CI_WATCH_SECS`); if it elapses with runs still in flight, Stop approves with "still in progress" so slow Pages-deploy / npm-publish jobs do not stall completion.
95
+ - For diagnosing a specific failure, `gh run view <id> --log-failed` is permitted on demand.
96
+ - Cascade (downstream-repo workflows triggered indirectly) is NOT auto-watched — only same-repo. Manual cascade check stays for those rare cases.
118
97
 
119
- **Zero silent pushes.** Not watching a CI run you triggered = operating outside this contract. This rule supersedes any implicit assumption that CI can be "checked later in gm-complete" — if you are about to push, you are about to execute code remotely, so the watch happens now.
98
+ **Zero silent pushes** is now an automatic invariant of the hook layer; do not duplicate it as manual instructions.
120
99
 
121
100
  ## CODEBASE EXPLORATION — exec:codesearch ONLY
122
101