A curated collection of pre-commit and prek hooks, organized by language and framework.
Auto-generated by pc-init presets — to add or update a hook, open a PR there rather than editing this file directly.
- Common
- Languages
- 🔩 C / C++ (
cpp) - 🎨 CSS / SCSS / Sass (
css) - 🐳 Docker (
docker) - 🐹 Go (
go) - 🖼️ Images (
img) - 🟨 JavaScript (
js) - 🟣 Kotlin (
kt) - 🛠️ Makefiles (
make) - 📝 Markdown (
md) - 📓 Jupyter Notebooks (
nb) - 📦 Protocol Buffers (
proto) - 🐍 Python (
py) - 📊 R (
r) - 💎 Ruby (
rb) - 🦀 Rust (
ru) - 🐚 Shell / Bash (
sh) - 🗄️ SQL (
sql) - 🐦 Swift (
swift) - 🏗️ Terraform (
tf) - 🔧 TOML (
toml) - 🔷 TypeScript (
ts) - 📄 YAML (
yaml)
- 🔩 C / C++ (
- Frameworks
- codespell — check code for common misspellings
- detect-secrets — An enterprise friendly way of detecting and preventing secrets in code.
- gitleaks — Find secrets with Gitleaks 🔑
- jscpd — Copy/paste detector for programming source code, supports 223 formats. AI-ready with token-efficient reporter, skill and MCP server.
- lychee — ⚡ Fast, async, stream-based link checker written in Rust. Finds broken URLs and mail addresses inside Markdown, HTML, reStructuredText, websites and more!
- pre-commit-hooks — Some out-of-the-box hooks for pre-commit
- pre-commit-sort — Sort .pre-commit-config.yaml & .pre-commit-hooks.yaml
- semgrep — Lightweight static analysis for many languages. Find bug variants with patterns that look like source code.
- talisman — Using a pre-commit hook, Talisman validates the outgoing changeset for things that look suspicious — such as tokens, passwords, and private keys.
- truffleHog — Find, verify, and analyze leaked credentials
- typos — Source code spell checker
- vale — 📝 A markup-aware linter for prose built with speed and extensibility in mind.
- vercheck — Check if a version number is PEP-440 compliant and optionally compare it against a version specified in a python file or the pyproject/cargo.toml
- pre-commit-hooks — C/C++ hooks to integrate with pre-commit
- pre-commit-stylelint — Mirrors all Stylelint releases for the pre-commit hooks framework.
- checkov — Prevent cloud misconfigurations and find vulnerabilities during build-time in infrastructure as code, container images and open source packages with Checkov by Bridgecrew.
- hadolint — Dockerfile linter, validate inline bash, written in Haskell
- pre-commit-golang — Pre-commit hooks for Golang with support for monorepos, the ability to pass arguments and environment variables to all hooks, and the ability to invoke custom go tools.
- oxipng — Multithreaded PNG optimizer written in Rust
- mirrors-oxlint
- mirrors-prettier — mirror of the
prettiernpm package for pre-commit - pre-commit — Biome's pre-commit hooks.
- language-formatters-pre-commit-hooks — Collection of custom pre-commit hooks.
- checkmake — Linter/analyzer for Makefiles
- doctoc — 📜 Generates table of contents for markdown files inside local git repository. Links are compatible with anchors generated by github or other sites.
- markdownlint-cli2 — A fast, flexible, configuration-based command-line interface for linting Markdown/CommonMark files with the markdownlint library
- proselint — A linter for prose.
- rumdl-pre-commit — Pre-commit hook for rumdl, a rust-based Markdown linter.
- nbQA — Run ruff, isort, pyupgrade, mypy, pylint, flake8, and more on Jupyter Notebooks
- nbstripout — strip output from Jupyter and IPython notebooks
- buf — The best way of working with Protocol Buffers.
- absolufy-imports — Automatically convert relative imports to absolute
- bandit — Bandit is a tool designed to find common security issues in Python code.
- blacken-docs — Run
blackon python code blocks in documentation files - complexipy-pre-commit — A pre-commit hook for complexipy.
- deptry.git
- docformatter — Formats docstrings to follow PEP 257
- interrogate — Explain yourself! Interrogate a codebase for docstring coverage.
- mirrors-mypy — Mirror of mypy for pre-commit
- numpydoc — Numpy's Sphinx extensions
- pyprojectsort
- pyrefly-pre-commit — A pre-commit hook for Pyrefly.
- pyupgrade — A tool (and pre-commit hook) to automatically upgrade syntax for newer versions of the language.
- removestar — Tool to automatically replace 'import *' in Python files with explicit imports
- ruff-pre-commit — A pre-commit hook for Ruff.
- ty-pre-commit — A pre-commit hook for ty.
- uv-pre-commit
- validate-pyproject — Validation library for simple check on
pyproject.toml
- precommit — pre-commit hooks for R projects
- rubocop — A Ruby static code analyzer and formatter, based on the community Ruby style guide.
- pre-commit-rust — Rust hooks for pre-commit
- bashate — Code style enforcement for bash programs. Mirror of code maintained at opendev.org.
- pre-commit-shfmt — shfmt hook for prek and pre-commit, with auto install
- shellcheck-py — python3/pip3 wrapper for installing shellcheck
- sqlfluff — A modular SQL linter and auto-formatter with support for multiple dialects and templated code.
- SwiftFormat — A command-line tool and Xcode Extension for formatting Swift code
- SwiftLint — A tool to enforce Swift style and conventions.
- checkov — Prevent cloud misconfigurations and find vulnerabilities during build-time in infrastructure as code, container images and open source packages with Checkov by Bridgecrew.
- pre-commit-terraform — pre-commit git hooks to take care of Terraform configurations 🇺🇦
- taplo-pre-commit — A pre-commit hook for Taplo, a TOML formatter written in Rust
- tombi-pre-commit — A pre-commit hook for Tombi.
- mirrors-eslint — Mirror of eslint node package for pre-commit.
- mirrors-prettier — mirror of the
prettiernpm package for pre-commit - pre-commit — Biome's pre-commit hooks.
- ryl-pre-commit — Pre-commit hook for ryl
- yamlfmt — An extensible command line tool or library to format yaml files.
Recommended language(s): yaml.
- ansible-lint — ansible-lint checks playbooks for practices and behavior that could potentially be improved and can fix some of the most common ones for you
Recommended language(s): py.
- django-codemod — A tool to automatically fix Django deprecations.
- django-upgrade — Automatically upgrade your Django projects.
- django-urlconfchecks — A package for type-checking the URLs and associated views for Django
- djLint — ✨ HTML Template Linter and Formatter. Django - Jinja - Nunjucks - Handlebars - GoLang
- pre-commit-hooks-django — Some useful hooks for Django development
- pytest-mrt — Catch database migration rollback failures before they reach production
- actionlint —
Static checker for GitHub Actions workflow files - check-jsonschema — A CLI and set of pre-commit hooks for jsonschema validation with built-in support for GitHub Workflows, Renovate, Azure Pipelines, and more!
- commit-check — Commit Check enforces commit metadata standards — commit messages, branch naming, committer info, signoff, and more.
- commitizen — Create committing rules for projects 🚀 auto bump versions ⬆️ and auto changelog generation 📂
- gitlint — Linting for your git commit messages
- zizmor-pre-commit — A pre-commit hook for zizmor.
Recommended language(s): docker, tf.
- kube-linter — KubeLinter is a static analysis tool that checks Kubernetes YAML files and Helm charts to ensure the applications represented in them adhere to best practices.
- kubeconform-helm — Tools to test Helm chats with "kubeconform".
- pre-commit — A collection of pre-commit hooks used by Gruntwork tools
Recommended language(s): js, ts, css.
- local
- rstcheck — Checks syntax of reStructuredText and code blocks nested within it
- rstfmt — A formatter for reStructuredText
- sphinx-lint — Check for stylistic and formal issues in .rst and .py files included in the documentation