CtrlK
BlogDocsLog inGet started
Tessl Logo

git-guardrails-claude-code

设置 Claude Code hooks,在危险 git commands(push、reset --hard、clean、branch -D 等)执行前阻止它们。适用于用户想防止破坏性 git 操作、添加 git safety hooks,或在 Claude Code 中阻止 git push/reset 时。

80

Quality

100%

Does it follow best practices?

Run evals on this skill

Adds up to 20 points to the overall score

View guide

SecuritybySnyk

Passed

No findings from the security scan

SKILL.md
Quality
Evals
Security

Quality

Content

100%

Reviews the quality of instructions and guidance provided to agents. Good implementation is clear, handles edge cases, and produces reliable results.

The body is concise, fully actionable with copy-paste config, clearly sequenced with an explicit verification step, and appropriately splits the hook logic into a real one-level-deep bundle reference. It avoids explaining concepts Claude already knows.

DimensionReasoningScore

Conciseness

The body is lean: no explanation of what git or hooks are, just the blocked-command list, sequenced steps, and necessary JSON/verify snippets, so every token earns its place per the score-3 anchor.

3 / 3

Actionability

It provides copy-paste-ready settings.json blocks for both project and global scope, exact target paths, 'chmod +x', and a concrete verification command, meeting the 'fully executable, copy-paste ready' anchor.

3 / 3

Workflow Clarity

Five explicitly sequenced steps culminate in a Verify step with a test command and expected exit code 2 / BLOCKED stderr output, an explicit validation checkpoint; it is not the score-2 case because validation is present and concrete rather than missing or implicit.

3 / 3

Progressive Disclosure

The hook implementation is appropriately split into the referenced bundle file [scripts/block-dangerous-git.sh] (confirmed to exist), a one-level-deep, clearly signaled reference, keeping the body an organized overview rather than a monolith.

3 / 3

Total

12

/

12

Passed

Description

100%

Based on the skill's description, can an agent find and select it at the right time? Clear, specific descriptions lead to better discovery.

The description is specific, uses natural trigger terms, explicitly answers both what and when, and occupies a clear non-conflicting niche. It uses third-person/impersonal voice with no first- or second-person penalty.

DimensionReasoningScore

Specificity

The description enumerates concrete commands to block ('push、reset --hard、clean、branch -D') and the concrete action of installing a PreToolUse hook, matching the 'lists multiple specific concrete actions' anchor rather than the vaguer score-2 example.

3 / 3

Completeness

It states both what ('设置 Claude Code hooks...阻止危险 git commands') and when ('适用于用户想...时'), with an explicit trigger clause equivalent to 'Use when', satisfying the both-what-and-when requirement that would otherwise cap at 2.

3 / 3

Trigger Term Quality

Natural user phrasing is well covered via '防止破坏性 git 操作', 'git safety hooks', and '阻止 git push/reset', plus the raw command names users would actually say; this exceeds the 'some relevant keywords' bar at score 2.

3 / 3

Distinctiveness Conflict Risk

The niche is narrow and specific — blocking destructive git commands via Claude Code hooks — with triggers unlikely to fire for unrelated skills, matching the 'clear niche with distinct triggers' anchor.

3 / 3

Total

12

/

12

Passed

Validation

100%

Checks the skill against the spec for correct structure and formatting. All validation checks must pass before discovery and implementation can be scored.

Validation16 / 16 Passed

Validation for skill structure

No warnings or errors.

Repository
vinvcn/mattpocock-skills-zh-CN
Reviewed

Table of Contents

Is this your skill?

If you maintain this skill, you can claim it as your own. Once claimed, you can manage eval scenarios, bundle related skills, attach documentation or rules, and ensure cross-agent compatibility.