# .git/hooks/pre-commit
#!/bin/sh
npm run lint
npm run test
# Cursor works with existing hooks
# AI can help write hooks:
"Create a pre-commit hook that:
- Runs ESLint
- Checks for console.log
- Validates commit message format"
Run npx skillmds@latest add tools-only/2730-git-hooks-integration-f00e46f3 in your terminal (requires Node.js), paste this page's agent-chat prompt into Claude, Cursor, or any MCP-connected agent, or download the SKILL.md file and copy it into your agent's skills directory.
Git Hooks Integration It is listed under Integrations & APIs on SkillMD.
This skill has not completed SkillMD's automated safety review yet. Independent scanners report: SkillSpector: PASS, Skill Scanner: PASS. SkillMD never runs a skill's scripts for you; review the SKILL.md before installing.
This skill is tagged as working with Claude Code, Claude.ai, OpenAI Codex. SKILL.md is an open format, so most agents that read a skills directory can load it too.
Yes. Installing skills from SkillMD is free, and the skill stays under its author's original license.
tools-only (@tools-only) published this skill. Their other Agent Skills are listed on their SkillMD profile.