Skip to content
Skill

Git hooks

Pre-commit and pre-push git hooks that run your project's justfile checks

Git hooks is an open-source agent skill for developer tools. It is available on Claude Code.

Scripts
None
Platforms
Claude Code
GitHub stars
6
Last commit
License
Apache-2.0
Listing updated

Similar skills

About Git hooks

This skill sets up git hooks for a project that uses a justfile. The pre-commit hook runs check-only format, lint and typecheck recipes so it stays quick. The pre-push hook runs the project's check-all recipe, which is level-aware, plus optional architecture and docs checks when the justfile defines them.

The hooks deliberately never rewrite files. Fixing formatting or lint issues is left to the developer, who runs the fixer recipes, re-stages and commits again, so the commit that lands is the one that was checked. The skill includes shell scripts for direct installation into .git/hooks and a configuration for the pre-commit framework, which suits teams because it stays in the repository.

It expects a justfile with recipes such as format-check, lint-check, typecheck and check-all, and it adds hooks-install and hooks-remove recipes for setup and removal. Git and the just command runner are needed, and the pre-commit framework is optional.

When your agent uses it

Pre-commit and pre-push hooks that call justfile recipes. Level-aware: pre-commit is fast; pre-push runs the level's gates.

From the skill's SKILL.md. Your agent reads this description to decide when to load the skill.

What it can access

From a static check of its 1 file (7 KB) on GitHub on 4 December 2026. Nothing was run. Read the files before you install a skill: it can tell your agent to run anything its tools allow.

Check another skill before you install it.

Install

This skill ships in the fff plugin. In Claude Code, add the marketplace and install the plugin (it may include other skills too):

/plugin marketplace add zerotechdebt/ffflow
/plugin install fff@ffflow

Or copy only this skill to ~/.claude/skills/git-hooks:

tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/zerotechdebt/ffflow.git "$tmp" &&
mkdir -p ~/.claude/skills &&
rm -rf ~/.claude/skills/git-hooks &&
cp -R "$tmp/plugin/skills/git-hooks" ~/.claude/skills/git-hooks &&
rm -rf "$tmp"

For one project only, put the folder in .claude/skills/git-hooks inside it instead.

Claude Code docs on skills

Copy the skill folder to ~/.agents/skills/git-hooks to use it in every repository:

tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/zerotechdebt/ffflow.git "$tmp" &&
mkdir -p ~/.agents/skills &&
rm -rf ~/.agents/skills/git-hooks &&
cp -R "$tmp/plugin/skills/git-hooks" ~/.agents/skills/git-hooks &&
rm -rf "$tmp"

For one repository only, put the folder in .agents/skills/git-hooks inside it instead.

Codex docs on skills

Copy the skill folder to ~/.cursor/skills/git-hooks to use it in every project:

tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/zerotechdebt/ffflow.git "$tmp" &&
mkdir -p ~/.cursor/skills &&
rm -rf ~/.cursor/skills/git-hooks &&
cp -R "$tmp/plugin/skills/git-hooks" ~/.cursor/skills/git-hooks &&
rm -rf "$tmp"

For one project only, put the folder in .cursor/skills/git-hooks inside it instead.

Cursor docs on skills

Run in a terminal (add --scope workspace to install it for the current workspace only):

gemini skills install https://github.com/zerotechdebt/ffflow.git --path plugin/skills/git-hooks

Or copy the folder to ~/.gemini/skills/git-hooks yourself.

Gemini CLI docs on skills

For GitHub Copilot in VS Code, copy the skill folder to ~/.copilot/skills/git-hooks:

tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/zerotechdebt/ffflow.git "$tmp" &&
mkdir -p ~/.copilot/skills &&
rm -rf ~/.copilot/skills/git-hooks &&
cp -R "$tmp/plugin/skills/git-hooks" ~/.copilot/skills/git-hooks &&
rm -rf "$tmp"

For one project only, put the folder in .github/skills/git-hooks inside it instead.

VS Code docs on skills

Get the folder:

git clone --depth 1 https://github.com/zerotechdebt/ffflow.git

Then copy ffflow/plugin/skills/git-hooks into your agent's skills folder as git-hooks. Agents that support SKILL.md read one folder per skill.

The SKILL.md format

What it does

Fast pre-commit checks
Runs format, lint and typecheck verification recipes on every commit without rewriting files.
Level-aware pre-push gates
Runs the project's check-all recipe, which adapts its gates to the project level.
Optional audit checks
Runs architecture and documentation drift checks only when the justfile defines those recipes.
Pre-commit framework config
Provides a .pre-commit-config.yaml so hooks are versioned with the repository and shared by the team.
Install and remove recipes
Adds justfile recipes that install hooks through pre-commit or by copying scripts into .git/hooks.
Check-only philosophy
Keeps hooks from fixing files after staging, so committed code matches what CI verifies.

Good for

  • Add pre-commit formatting and lint checks to a new project
  • Set up a pre-push hook that runs the full check suite before pushing
  • Install git hooks for a team using the pre-commit framework
  • Remove previously installed git hooks from a repository
  • Make local checks match the gates CI runs

Git hooks FAQ

What does the pre-commit hook run?

It runs the just recipes format-check, lint-check and typecheck, and stops on the first failure.

Does the hook fix formatting or lint errors automatically?

No. Hooks only check. When a check fails, the developer runs just format lint, re-stages the changes and commits again.

How do I skip the hooks?

Use git commit --no-verify or git push --no-verify. The skill advises this only for cases such as WIP commits on feature branches.

Which tools does Git hooks need?

It needs the just command runner and a justfile in the project. The pre-commit framework is optional and used for the team setup.

How do I install Git hooks in Claude Code?

Copy the skill folder from GitHub to ~/.claude/skills/git-hooks to use it in all your projects, or to .claude/skills/git-hooks in one project. Or install the fff plugin, which includes it: /plugin marketplace add zerotechdebt/ffflow, then /plugin install fff@ffflow.

Does Git hooks run scripts?

No. It is instructions only, with no scripts. This comes from a static check of the files on GitHub; nothing was run. Read the files before you install it.

Which AI agents can use Git hooks?

Claude Code. It reads skills in the SKILL.md format; the install steps on this page show where to put the folder.

What are the best alternatives to Git hooks?

The closest alternatives to Git hooks are Init prettier git hooks, Justfile, Code quality tooling edho ferdian, Vibe pre commit audit and Ci gates.

Where this comes from

  • Description: from the skill's own SKILL.md.

More from zerotechdebt/ffflow

  1. Onboards a project onto FFFlow: config, stack setup, then a phased roadmap

    • Open source
    • 6 GitHub stars
    • Developer tools
  2. Runs keep-honest audits on a project and reports drift, stale docs and tech debt

    • Open source
    • 6 GitHub stars
    • Developer tools
  3. Runs another interactive skill unattended, making routine choices from project context

    • Open source
    • 6 GitHub stars
    • Developer tools
  4. Lists and validates the adapter cartridges that FFFlow ports load in a project

    • Open source
    • 6 GitHub stars
    • Developer tools
  5. Extracts a behavioral spec from an unspecified codebase and plans characterization tests

    • Open source
    • 6 GitHub stars
    • Developer tools
  6. Adds GitHub Actions workflows that run FFFlow quality gates on pull requests

    • Open source
    • 6 GitHub stars
    • Developer tools