CtrlK
BlogDocsLog inGet started
Tessl Logo

setup-pre-commit

在当前仓库设置 Husky pre-commit hooks,集成 lint-staged (Prettier)、类型检查和测试。适用于用户想添加 pre-commit hooks、设置 Husky、配置 lint-staged,或在提交时运行格式化、类型检查和测试时。

70

Quality

85%

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

82%Weight 40%Scale 1-5

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

The body is a tight, actionable, well-sequenced setup recipe with concrete configs and a verification checklist. Its main gaps are the missing explicit install command and the absence of an error-recovery feedback loop in the verify step.

Suggestions

Make the install step executable by giving the actual command, e.g. `npm install -D husky lint-staged prettier` (adapted per detected package manager), instead of just listing package names.

Add an explicit feedback loop to the Verify step: if `npx lint-staged`, `npm run typecheck`, or `npm run test` fail, fix the reported issue and re-run before committing.

Note in step 4 that the pre-commit file must be made executable (chmod +x) for Husky versions/configs that require it, since the checklist asserts it is executable but no step ensures that.

DimensionReasoningScore

Conciseness

Lean recipe-style content that assumes Claude's competence — gives commands and config without explaining what Husky or Prettier are, and the Notes section adds only non-obvious value (Husky v9 shebang behavior, --ignore-unknown, run ordering).

5 / 5

Actionability

Copy-paste-ready pre-commit file, .lintstagedrc and .prettierrc configs, but the install step only lists package names ("husky lint-staged prettier") without the concrete install command, a minor executable gap.

4 / 5

Workflow Clarity

Eight clearly numbered steps with a Verify checklist (step 7) and a commit smoke test (step 8), but lacks an explicit error-recovery feedback loop if lint-staged/typecheck/test fail.

4 / 5

Progressive Disclosure

Self-contained single-file skill with well-organized sections (What This Sets Up, Steps, Notes) and no external references needed; good structure with minor organization gaps rather than a perfectly split overview-plus-references layout.

4 / 5

Total

17

/

20

Passed

Description

87%Weight 40%Scale 1-5

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 well-crafted: third-person voice, explicit what-and-when structure with a concrete trigger clause, and a distinct niche. Minor weakness is that the capability list is bundled rather than enumerated, costing a touch of specificity and synonym coverage.

DimensionReasoningScore

Specificity

Lists several concrete actions ("设置 Husky pre-commit hooks", "集成 lint-staged (Prettier)、类型检查和测试") but bundles them into a single setup verb rather than enumerating distinct granular actions, leaving minor coverage gaps.

4 / 5

Completeness

Explicitly answers both 'what' (sets up Husky hooks integrating lint-staged, typecheck, tests) and 'when' with a concrete "适用于...时" trigger clause, matching the top anchor.

5 / 5

Trigger Term Quality

The trigger clause "适用于用户想添加 pre-commit hooks、设置 Husky、配置 lint-staged,或在提交时运行格式化、类型检查和测试时" covers the natural terms users would say, though it lacks broader synonyms or file-extension variants.

4 / 5

Distinctiveness Conflict Risk

Occupies a clear niche (pre-commit hook setup with named tools Husky/lint-staged/Prettier) with distinct triggers and minimal overlap risk with other skills.

5 / 5

Total

18

/

20

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.