ghm-template-sync

ghm-template-sync is a skill for Claude Code from mattgierhart/PRD-driven-context-engineering. It costs 82 tokens per session (1,121 once invoked), scanned A, original, MIT.

A tool for comparing a project with its starting template and moving it to a newer template version. It checks files and structure, then identifies safe updates while preserving project-specific content.

In plain words
What is it for?
Use it to check template drift, list missing or outdated files, and guide a repository migration to the latest template.
Why use it?
It helps find template changes that a project may have missed and reduces the risk of updating shared files incorrectly.

Skill for Claude Code

Written for Claude Code: allowed-tools in frontmatter. Also seen: reads .claude/ paths; mentions CLAUDE.md.

Good fit Use it to check template drift, list missing or outdated files, and guide a repository migration to the latest template.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/mattgierhart/prd-driven-context-engineering/ghm-template-sync
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add mattgierhart/PRD-driven-context-engineering --skill ghm-template-sync
Clone the repo
git clone --depth 1 https://github.com/mattgierhart/PRD-driven-context-engineering

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for ghm-template-sync

README.md
[![agentmods](https://agentmods.dev/badge/skills/mattgierhart/prd-driven-context-engineering/ghm-template-sync/github.svg)](https://agentmods.dev/skills/mattgierhart/prd-driven-context-engineering/ghm-template-sync)
Your own site
<a href="https://agentmods.dev/skills/mattgierhart/prd-driven-context-engineering/ghm-template-sync"><img src="https://agentmods.dev/badge/skills/mattgierhart/prd-driven-context-engineering/ghm-template-sync/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for ghm-template-sync

Your own site · 80×15
<a href="https://agentmods.dev/skills/mattgierhart/prd-driven-context-engineering/ghm-template-sync"><img src="https://agentmods.dev/badge/skills/mattgierhart/prd-driven-context-engineering/ghm-template-sync.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 82 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,121 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector warn 7 Sept 2026
SkillSpector: 2 findings, up to high

These are SkillSpector’s own severities. On a checked sample its high-severity flags on skills were ~96% false positives — a documented command, a public API, a “never do X” rule — so we show them as a caution to read, not a verdict. Why →

  • high Memory Poisoning · line 113
    Skill manipulates agent memory, state, or stored context. Memory corruption can alter personality, override safety rules, or cause unpredictable behavior.
    Fix: Protect agent memory and state from modification by untrusted content. Use read-only memory for critical instructions and validate all state changes.
  • medium Excessive Agency · line 76
    Skill enables autonomous high-impact decisions without human-in-the-loop verification. Critical operations (destructive commands, financial transactions, data deletion) should require explicit user confirmation.
    Fix: Add human-in-the-loop confirmation for destructive, irreversible, or high-impact operations. Never auto-execute commands that modify files, send data, or alter system state.
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00082 $0.01121
Opus 5.5 $0.00033 $0.00448
Sonnet 5.5 $0.00016 $0.00224
Haiku 4.5 $0.00008 $0.00112

Measured 1mo ago against content hash 852eb2d1faf7, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

ghm-template-sync scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.claude/skills/ghm-template-sync/SKILL.md · 119 lines

How it starts

The opening of the file, as written. The whole thing — 119 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Template Sync

Detect template version drift and migrate to the latest template version.

Workflow

Phase 1: Detect Current State

  1. Read .claude/VERSION (if it exists) to get current template version
  2. If no VERSION file, check CLAUDE.md frontmatter for template_version
  3. If neither exists, assume v1.0.0 (pre-versioning)
  4. Report: "Your repo is on template v{X}. Latest is v{Y}."

Phase 2: Diff Against Template

Compare your repo structure against what the current template version expects:

Check for missing files:

  • .claude/VERSION
  • .claude/domain-profile.yaml
  • .claude/hooks/HOOK_CONTRACT.md
  • .claude/hooks/context-validation.sh
  • .claude/hooks/context-density-gate.sh
  • .claude/hooks/sot-update-trigger.sh
  • CHANGELOG.md
  • MIGRATION.md

Check for stale files (should be removed):

  • .claude/hooks/context-validation.py
  • .claude/hooks/context-density-gate.py
  • .claude/hooks/sot-update-trigger.py
  • .claude/agents/HORIZON.md (replaced by subdirectory)
  • .claude/agents/STUDIO.md
  • .claude/agents/DEVLAB.md
  • .claude/agents/METRO.md

Check for structure issues:

  • settings.json: Does it use 3-level nesting? Are timeouts in seconds?
  • Agent directories: Do horizon/, studio/, devlab/, metro/ subdirectories exist with AGENT.md + MEMORY.md?
  • EPIC template: Does it use semantic headers (not numbered)?
  • Frontmatter: Do key files have template_version?

Phase 3: Generate Migration Plan

Output a table:

File Status Action Risk
.claude/VERSION Missing Copy from template None
.claude/hooks/*.py Stale Delete (replaced by .sh) None
.claude/agents/HORIZON.md Stale Split into horizon/AGENT.md + MEMORY.md Preserve MEMORY.md content
settings.json Outdated Update hook nesting + commands Check for custom hooks
CLAUDE.md Missing frontmatter Add template_version: "3.0.0" None

Phase 4: Execute Safe Updates

Read the full file on GitHub · 119 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 1mo ago First seen · 119 lines · 82 tokens per session scan A 852eb2d1faf7

Subscribe to this mod's changes

ghm-template-sync is a skill published in the GitHub repository mattgierhart/PRD-driven-context-engineering (181 stars, last pushed 1mo ago), licensed MIT. It adds 82 tokens to every session and 1,121 once invoked, about $0.0003 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.