From gm
Refreshes README.md, CLAUDE.md, docs/index.html, and gm.md to match recent codebase changes. Uses git analysis, targeted updates, verification, commit, and push. Terminal phase post-verification.
npx claudepluginhub anentrypoint/gm-cc --plugin gmThis skill uses the workspace's default tool permissions.
You are in the **UPDATE-DOCS** phase. Feature work is verified and pushed. Refresh all documentation to match the actual codebase state right now.
Implements two-phase workflow to analyze code changes via git diff and update project documentation. Use before merging branches, after features/bugfixes, or when docs stale.
Researches current code state and updates feature documentation under docs/features/ to keep docs in sync with code changes after commits or manually.
Updates project documentation (README, API docs, auto-detect) based on recent git changes. Asks scope, analyzes diffs, spawns docs-keeper agent, verifies links/examples.
Share bugs, ideas, or general feedback.
You are in the UPDATE-DOCS phase. Feature work is verified and pushed. Refresh all documentation to match the actual codebase state right now.
GRAPH POSITION: PLAN → EXECUTE → EMIT → VERIFY → [UPDATE-DOCS] → COMPLETE
gm-complete.FORWARD: All docs updated, committed, and pushed → COMPLETE (session ends)
BACKWARD:
planning skill, restart chainStep 1 — Understand what changed:
exec:bash
git log -5 --oneline
git diff HEAD~1 --stat
Witness which files changed. Identify doc-sensitive changes: new skills, new states in the state machine, new platforms, modified architecture, new constraints, renamed files.
Step 2 — Read current docs:
exec:nodejs
const fs = require('fs');
['README.md', 'CLAUDE.md', 'docs/index.html',
'plugforge-starter/agents/gm.md'].forEach(f => {
try { console.log(`=== ${f} ===\n` + fs.readFileSync(f, 'utf8')); }
catch(e) { console.log(`MISSING: ${f}`); }
});
Identify every section that no longer matches the actual codebase state.
Step 3 — Write updated docs:
Write only sections that changed. Do not rewrite unchanged content. Rules per file:
README.md: platform count matches adapters in platforms/, skill tree diagram matches current state machine, quick start commands work.
CLAUDE.md: Only non-obvious technical caveats that required multiple runs to discover — things that could not be known without hitting the problem first. Remove anything that no longer applies. Never add anything obvious from reading the code or that any developer would already know. The test: "would a developer need to discover this the hard way, or is it self-evident?" If self-evident, exclude it.
docs/index.html: PHASES array matches current skill state machine phases. Platform lists match platforms/ directory. State machine diagram updated if new phases added.
plugforge-starter/agents/gm.md: Skill chain on the gm skill → line updated if new skills were added.
exec:nodejs
const fs = require('fs');
fs.writeFileSync('/abs/path/file.md', updatedContent);
Step 4 — Verify from disk:
exec:nodejs
const fs = require('fs');
const content = fs.readFileSync('/abs/path/file.md', 'utf8');
console.log(content.includes('expectedString'), content.length);
Witness each written file from disk. Any variance from expected content → fix and re-verify.
Step 5 — Commit and push:
exec:bash
git add README.md CLAUDE.md docs/index.html plugforge-starter/agents/gm.md
git diff --cached --stat
Witness staged files. Then commit and push:
exec:bash
git commit -m "docs: update documentation to reflect session changes"
git push -u origin HEAD
Witness push confirmation. Zero variance = COMPLETE.
Every claim in docs must be verifiable against disk right now:
name: frontmatterplatforms/If a doc section cannot be verified against disk: remove it, do not speculate.
Never: skip diff analysis | write docs from memory alone | push without verifying from disk | add comments to doc content | claim done without witnessed push output
Always: witness git diff first | read current file before overwriting | verify each file from disk after write | push doc changes | confirm with witnessed push output
→ COMPLETE: Docs committed and pushed → session ends.
↩ SNAKE to PLAN: New unknown about codebase state → invoke planning skill.