sync-docs
Skill50 starsChanged 4 days agoMITView on GitHub
Use when the user asks to sync, update, or refresh CLAUDE.md, AGENTS.md, SKILL.md, and README.md to reflect recent commits or PRs. Triggers on phrases like "sync docs", "update CLAUDE.md", "update AGENTS.md", "update SKILL.md", "update README", "reflect recent changes", or "document the recent PRs".
22 other projects use a version of this.
Adopted by
Most recently taken up by
- Kangentic/kangentictheir own version, first seen Nov 7, 2026
- TanKaizokuO/claude-skillstheir own version, first seen Oct 20, 2026
- blakebauman/memoturn-dbtheir own version, first seen Oct 13, 2026
- yokeloop/yoketheir own version, first seen Oct 9, 2026
- kube-hetzner/terraform-hcloud-kube-hetznertheir own version, first seen Oct 8, 2026
- ayutaz/piper-plustheir own version, first seen Oct 8, 2026
Used with
Projects with it also use prepare-release, review-pr and 2 more.
Other files people use alongside this one.
Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
ShopifySkillprepare-release
Prepare the changeset-release/main branch for release by syncing version.ts files and running pnpm install
Also in 4 projects that use this
DockerSkillreview-pr
Review one or more incoming Docker documentation pull requests as a maintainer. Independently validate technical claims, assess editorial fit and information architecture, choose a verdict, and draft exact inline or PR-wide feedback behind a confirmation gate. Use for requests such as "review PR 123", "is this PR correct?", "does this information belong here?", "validate this PR", or "help review backlog PRs". Do not use to maintain or fix a PR you own; use maintain-pr for that.
Also in 3 projects that use this
MicrosoftSkillrelease
Use ONLY when the user explicitly asks to cut/publish a Huabu desktop release or tag a version. Performs an outward action — bumps the version in apps/desktop/package.json, commits + annotated-tags vX.Y.Z, and pushes the branch + tag. That tag push auto-builds the macOS/Windows installers and publishes a GitHub Release. Provides `status`, `bump`, `tag-push`, and a one-command `run` (bump → tag-push).
Also in 3 projects that use this
MicrosoftSkillhandoff
Compact the current conversation into a handoff document for another agent to pick up.
Also in 3 projects that use this
Other versions22 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 22
- kube-hetzner/terraform-hcloud-kube-hetzner★ 3.9ksame name
- mysticaltech/terraform-hcloud-kube-hetzner★ 3.9ksame name
- onevcat/Prowl★ 673same name
- ayutaz/piper-plus★ 240same name
- joshzyj/open-scholar-skill★ 177same name
- Kangentic/kangentic★ 140same name
- guess/claude_code★ 96same name
- jiahao-shao1/sjh-skills★ 43same name
- phj128/autoworker★ 18same name
- whchoi98/claude-code-dashboard★ 16same name
12 more not listed
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository39 other files it gives its agents.
- CLAUDE.mdCLAUDE.md
- app-prdSkill
- cli-dispatchSkill
- codex-validate-plan-work-on-issueSkill
- create-releaseSkill
- execution-plan-reviewSkill
- expo-app-initializeSkill
- fable-advisorSkill
- fable-dispatchSkill
- fable-new-issue-loopSkill
- fable-new-issueSkill
- fable-orchestrateSkill
- fableplan-loopSkill
- fableplanSkill
- fableplan-work-on-issueSkill
- fable-validate-fableplan-loopSkill
- fable-validate-fableplanSkill
- fable-validate-loopSkill
- fable-validateSkill
- fix-pr-review-loopSkill
- fix-pr-reviewSkill
- github-issue-formatSkill
- issueplanSkill
- milestoneplanSkill
- milestone-workflowSkill
- new-app-pipelineSkill
- new-issue-loopSkill
- new-issueSkill
- prd-questionsSkill
- prd-to-issuesSkill
- pr-reviewSkill
- sync-docs-releaseSkill
- tldrSkill
- validate-fableplan-loopSkill
- validate-issue-loopSkill
- validate-issueSkill
- wansSkill
- work-on-issue-loopSkill
- work-on-issueSkill
The file
We split this skill into the rules it gives an agent
1 rule. 0 are common, 0 are distinctive, and 1 is very specific to this project.
0
Common
Most of the 19 edited versions we read keep these.
0
Distinctive
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 8
Keep CLAUDE.md, AGENTS.md, SKILL.md, and README.md accurate after new commits land: find the last docs-sync point, classify every commit …
“Common” is measured: kept by at least 6 in 10 of the 19 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
sync-docs
Keep CLAUDE.md, AGENTS.md, SKILL.md, and README.md accurate after new commits land: find the last docs-sync point, classify every commit since then, and write targeted edits. Syncing is bidirectional: add what is new, and remove or correct anything the current codebase contradicts.
Edit the docs that exist; never create a new top-level doc (AGENTS.md, CHANGELOG.md, SKILL.md) during a sync. If one seems warranted, tell the user.
Audiences: CLAUDE.md is the dense agent reference (architecture, symbol and file names, file:line cues) and describes current behavior, never history. AGENTS.md mirrors it for other agent tools (step 5). SKILL.md is operator-facing and imperative (config keys, setup, CLI flows); no symbol or field names in its tables. README.md is the newcomer entry point and changes only when the public surface changes. CHANGELOG.md, when present, holds per-issue rationale and migration history.
Preconditions: gh auth status succeeds. Resolve DEFAULT=$(gh repo view --json defaultBranchRef -q .defaultBranchRef.name), run git fetch origin, record the range end T0=$(git rev-parse "origin/$DEFAULT"), and create a worktree off that tip with the harness branch prefix (cc/ on Claude Code): git worktree add .claude/worktrees/cc+sync-docs-<YYYY-MM-DD> -b cc/sync-docs-<YYYY-MM-DD> "$T0". Every range below ends at $T0, never at a later origin/$DEFAULT. When that branch already exists locally or on origin, never delete or reuse it: add the next free suffix to the branch and the worktree name (-2, then -3). Read, edit, and run every git command in that worktree (-C <worktree>), never in the main checkout.
Steps
- Baseline.
git log --oneline "origin/$DEFAULT" | grep -m1 -E '^[0-9a-f]+ ([Ss]ync docs\b|docs(\([^)]*\))?: sync\b|docs\(sync\):)'. A sync is adocs:ordocs(<scope>):subject that begins with "sync", adocs(sync):scope, or a subject that begins with "sync docs"; a commit that mentions "sync docs" later in its subject is no sync, and a docs commit that only names CLAUDE.md or SKILL.md is no sync. The matched commitMis the baseline unless it records a range end: readgit log -1 --format=%B <M>for aDocs-sync-range-end: <sha>line; when the body has none and the subject ends with(#N)(a squash merge), readgh pr view <N> --json body -q .bodyfor that line. When a recorded<sha>exists andgit merge-base --is-ancestor <sha> "origin/$DEFAULT"holds, the baseline is<sha>; otherwise it isM. If none, ask the user for the last-known-good tag or SHA, or use the initial commit for a first sync. - Range.
git log <baseline>.."$T0" --oneline. Skip pure CI, workflow, and chore commits unless they change agent- or operator-facing behavior. - Classify each commit (an unrelated-areas commit is classified per area):
| Category | Docs target | Action |
| New config field / flag | CLAUDE.md config; SKILL.md settings table; README.md only for a public top-level setting | Add field description |
| Changed default behavior | CLAUDE.md patterns; SKILL.md; README.md only if a documented example now contradicts the code | Update; note old vs new |
| New pluggable unit (plugin, command, integration, provider, theme) | Every doc that enumerates the set | Add one entry per doc |
| Bug fix (behavior change) | CLAUDE.md patterns, if pattern-level | Update the bullet |
| New CLI command / flag | SKILL.md commands; README.md Getting Started only if part of setup | Add usage |
| Setup / install flow change | README.md Getting Started; SKILL.md if operator-facing | Update the block |
| Removed field | Whichever doc lists it | Delete the row or bullet |
| Behavior reversal (fix reverted) | Whichever doc carries it | Note the revert explicitly |
| Internal refactor / test | Skip | none |
| Release milestone | Project notes file, if one exists (step 9) | Append version entry |
| Rationale or migration history (CHANGELOG.md exists) | CHANGELOG.md | Keyed entry there; CLAUDE.md keeps only the current invariant |
| Doc claim contradicted by code | Whichever doc carries the claim | Correct or delete it |
- Audit docs near in-scope commits. Verify surrounding claims: paths exist, symbol names match, defaults and versions are current, CLI flags accept the documented args. Delete or correct what the code contradicts; grep first, and never remove a claim you haven't verified is wrong. Stay scoped; if the docs look broadly drifted, flag it instead of rewriting. Check "current/active/default" claims against the deciding switch (build target, feature-flag default, active-environment key), never against the doc's own prior text. When a commit touches a directory of pluggable items,
lsit and diff against every catalog, index, and README list. When one item is promoted and another retired, confirm the active state (self-referencing URLs, indexing directives, flags, defaults) flipped on both; if that invariant is real but undocumented, add a short rule. - Edit CLAUDE.md, then mirror into AGENTS.md. Edit only changed sections; terse bullets, one behavioral change each; update any schema or config version constant a migration bumped; rewrite PR descriptions as imperative phrases. Then
ls -l AGENTS.md: symlink to CLAUDE.md, skip it and never open it for writing; real file, apply every CLAUDE.md body edit verbatim, keep its own intro line, and audit it per step 4; absent, skip. - Edit SKILL.md (only if the repo has one). Add new keys to the settings table and the upgrade or post-update reference; update commands, reload scope, and safety-control sections when those surfaces change.
- Edit README.md (only if the public surface changed). Default to no edit. Touch it only for a new supported feature or integration, a new public unit in an enumerated list, a new top-level CLI subcommand, a setup or install change, or a public config example the code now contradicts. Tutorial tone: no
file:linecues, internals, or PR numbers; one line per list item in the existing format. Always check its enumerated lists for new public units. - Size check.
wc -c CLAUDE.md. Above 35000 bytes, condense in place to under 30000; never split it. Keep symbol and file names, field lists, enum values, defaults, version numbers, gotchas, concurrency and ordering rules, live behavior, the Environment, Setup, Build & Deploy, and Testing blocks, lookup tables of IDs, paths, or prefixes, and repo-defined format conventions. Drop "why" prose where the rule alone is actionable, shipped-migration narrative, resolved-incident stories, duplicates, and examples that restate a rule; move history to CHANGELOG.md when it exists. Re-runwc -cand report old and new counts. Still over 40000, list the largest sections and ask the user which to cut. - Project notes file, if the repo keeps one with a Releases section and the range includes a version tag or release PR: append
- **vX.Y.Z** — YYYY-MM-DD: <summary> (PRs #N, #M). - Land the edits through a PR.
git statusin the worktree. Stage only the doc files this sync changed, by name. Nothing staged: report "no doc changes", remove the worktree and delete its unpushed local branch (git branch -D <branch>), and stop. Otherwise commit with a subject that matches the step 1 baseline pattern (docs: sync <what> after <range>, ordocs(sync): ...), a body lineDocs-sync-range-end: $T0(the full SHA), and the repo's commit footer, push the branch, open a PR against$DEFAULTwhose title begins with that same subject (plus any title suffix the repo's PR convention requires, such as[C<score>, <model>, <effort>]) and whose body follows the repo's PR body rules and carries the sameDocs-sync-range-end: $T0line, and report its number and URL. A standalone run leaves the PR open for review; a caller such assync-docs-releaseowns the merge decision.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

