git-guardrails-claude-code SKILL.md skillC
git-guardrails-claude-code from ctaxnagomi/agent-kd-skill is an agent skill: a SKILL.md folder an AI agent loads when a task calls for it.
mdr add ctaxnagomi/agent-kd-skill/git-guardrails-claude-code@git:20260826.54f6831Pins git:20260826.54f6831 in mdr.lock. Pin the fingerprint instead.
- Audit grade
- C, 15 of 17 checks passed
- Kind
- SKILL.md skill
- Repository
- ctaxnagomi/agent-kd-skill
- Path
skills/custom/git-guardrails-claude-code/SKILL.md- Versions recorded
- 3
- Latest version
- git:20260826.54f6831, committed Aug 26, 2026
- First version recorded
- Aug 24, 2026
- Size
- 2,175 bytes
- Repository stars
- 3
- License
- none declared
Collected from public GitHub. Every version is saved exactly as it was and never changes. Install it at an exact version with the mdr tool, and every file is checked before it reaches your agent. The main file is checked against the SHA-256 fingerprint recorded here, and the others against the fingerprints GitHub keeps for its source commit. The automatic checks below grade the latest version, and the same checks always give the same file the same grade.
What the file says
# Git Guardrails (Claude Code) Set up Claude Code hooks to block dangerous git commands before they execute. ## What Gets Blocked - git push (all variants including --force) - git reset --hard - git clean -f / git clean -fd - git branch -D - git checkout . / git restore . ## Steps 1. **Ask scope** — This project only or all projects? 2. **Copy the hook script** — To .claude/hooks/ or ~/.claude/hooks/. 3. **Add hook to settings** — PreToolUse hook in settings.json. 4. **Ask about customization** — Add or remove patterns. 5. **Verify** — Test with a blocked command. ## Credit This skill is based on the work of **Matt Pocock** ([@mattpocock](https://github.com/mattpocock)). Original source: [mattpocock/skills](https://github.com/mattpocock/skills). Licensed under MIT. --- ## How to use? ### 1. Download Go to the [AGENT KD SKILL gallery](https://ctaxnagomi.github.io/agent-kd-skill/) and find this skill card. Click **Download** to save the SKILL.md file to your computer. ### 2. Install Copy the downloaded SKILL.md into your agent's skills directory: | Agent | Path | |-------|------| | **opencode** | ~/.config/opencode/skills/<skill-name>/SKILL.md | …
Read the whole file at its exact version.
How to install
mdr add ctaxnagomi/agent-kd-skill/git-guardrails-claude-code@sha256:4472244759bb7f1dThe line at the top of this page pins the label git:20260826.54f6831, which is what most people want. This one pins the sha256 fingerprint of the contents instead, so it survives a label being moved. Either way the exact version is written to mdr.lock, and mdr install downloads and checks those contents again, so it installs them exactly or stops with an error.
[](https://markdownregistry.com/a/art_miuxliixvu6vay67)
3 badge image fetches in 30 days. What the badge shows.
Versions
The registry has recorded 3 versions of this file, between Aug 24, 2026 and Aug 26, 2026, more than one a day.
| version | committed | commit | size | audit | |
|---|---|---|---|---|---|
| git:20260826.54f6831 latest | 2026-08-26 | 54f6831 | 2,175 B | C | view · diff |
| git:20260824.dfd64f3 | 2026-08-24 | dfd64f3 | 2,177 B | C | view · diff |
| git:20260824.da779f9 | 2026-08-24 | da779f9 | 1,113 B | C | view |
Audit of the latest version
- fail: Frontmatter declares a name
- fail: Frontmatter declares a description
- pass: Frontmatter block present
- pass: Size between 200 bytes and 200 KB (2175 bytes)
- pass: No zero-width or bidi control characters
- pass: No instruction hidden inside an HTML comment
- pass: No link to an exfiltration or paste host
- pass: No credential-shaped string
- pass: No instruction to send local credentials anywhere
- pass: No text hidden with inline styles
- pass: No prompt-injection phrasing
- pass: No curl or wget piped into a shell
- pass: No recursive delete of root, home or parent
- pass: No instruction to read or print local credentials
- pass: No base64 blob over 200 characters
- pass: No link to a raw IP address
- pass: No script tag
Starting a new one? Use a template for SKILL.md on mdpantry, which passes every one of these checks and says what to change in it.
Source
ctaxnagomi/agent-kd-skill · 3 stars · license none declared · pushed 2026-10-14 · branch master
API
GET https://markdownregistry.com/api/v1/artifacts/art_miuxliixvu6vay67 GET https://markdownregistry.com/api/v1/resolve?ref=ctaxnagomi/agent-kd-skill/git-guardrails-claude-code GET https://markdownregistry.com/api/v1/blob/4472244759bb7f1d2d7b0d3747101c9b87dfec10bb999cc43703b9f24f0371f1
Your AI assistant does the legwork. You hear about the deals worth your word. Hand yours the standing instructions at modelranch.com and it joins the network that reads files like this one.
Guides: the SKILL.md format and its required fields · what to check before you install a skill · how to pin a skill to an exact version · where to find agent skills · keeping a team on the same skills · which agent file does what.
More from ctaxnagomi/agent-kd-skill
Every file in ctaxnagomi/agent-kd-skill