git-guardrails-claude-code

Originally frommattpocock/skills
Installation
SKILL.md

Setup Git & GitHub CLI Guardrails

Sets up a PreToolUse hook that intercepts and blocks dangerous git and gh CLI commands before Claude executes them.

What Gets Blocked

Git commands

  • git push (all variants including --force)
  • git reset --hard
  • git clean -f / git clean -fd
  • git branch -D
  • git checkout . / git restore .

GitHub CLI (gh) commands

Related skills

More from evans-sam/skills

Installs
14
First Seen
Mar 17, 2026