# pre-commit

> A framework for managing and maintaining multi-language pre-commit hooks.

- **URL**: https://www.freshcrate.ai/projects/pre-commit
- **Author**: Anthony Sottile
- **Category**: Frameworks
- **Latest version**: `v4.6.0` (2026-04-21)
- **License**: MIT
- **Source**: https://github.com/pre-commit/pre-commit
- **Language**: Python
- **GitHub**: 15,176 stars, 953 forks
- **Registry**: pypi (`pre-commit`)
- **Tags**: `pypi`

## Description

[![build status](https://github.com/pre-commit/pre-commit/actions/workflows/main.yml/badge.svg)](https://github.com/pre-commit/pre-commit/actions/workflows/main.yml)
[![pre-commit.ci status](https://results.pre-commit.ci/badge/github/pre-commit/pre-commit/main.svg)](https://results.pre-commit.ci/latest/github/pre-commit/pre-commit/main)

## pre-commit

A framework for managing and maintaining multi-language pre-commit hooks.

For more information see: https://pre-commit.com/

## Recent releases

| Version | Date | Urgency | Changes |
| --- | --- | --- | --- |
| `v4.6.0` | 2026-04-21 | High | ### Features - `pre-commit hook-impl`: allow `--hook-dir` to be missing to enable easier usage with `git` 2.54+ git hooks.     - #3662 PR by @asottile.  ### Fixes - `pre-commit hook-impl`: `--hook-type` is required.     - #3661 PR by @asottile. |
| `4.5.1` | 2026-04-21 | Low | Imported from PyPI (4.5.1) |
| `v4.5.1` | 2025-12-16 | Low | ### Fixes - Fix `language: python` with `repo: local` without `additional_dependencies`.     - #3597 PR by @asottile. |
| `v4.5.0` | 2025-11-22 | Low | ### Features - Add `pre-commit hazmat`.     - #3585 PR by @asottile. |
| `v4.4.0` | 2025-11-08 | Low | ### Features - Add `--fail-fast` option to `pre-commit run`.     - #3528 PR by @JulianMaurin. - Upgrade `ruby-build` / `rbenv`.     - #3566 PR by @asottile.     - #3565 issue by @MRigal. - Add `language: unsupported` / `language: unsupported_script` as aliases for `language: system` / `language: script` (which will eventually be deprecated).     - #3577 PR by @asottile. - Add support docker-in-docker detection for cgroups v2.     - #3535 PR by @br-rhrbacek.     - #3360 issue by @JasonA |
| `v4.3.0` | 2025-08-09 | Low | ### Features - `language: docker` / `language: docker_image`: detect rootless docker.     - #3446 PR by @matthewhughes934.     - #1243 issue by @dkolepp. - `language: julia`: avoid `startup.jl` when executing hooks.     - #3496 PR by @ericphanson. - `language: dart`: support latest dart versions which require a higher sdk   lower bound.     - #3507 PR by @bc-lee. |
| `v4.2.0` | 2025-03-18 | Low | ### Features - For `language: python` first attempt a versioned python executable for the default language version before consulting a potentially unversioned `sys.executable`.     - #3430 PR by @asottile.  ### Fixes - Handle error during conflict detection when a file is named "HEAD"     - #3425 PR by @tusharsadhwani. |
| `v4.1.0` | 2025-01-20 | Low | ### Features - Add `language: julia`.     - #3348 PR by @fredrikekre.     - #2689 issue @jmuchovej.  ### Fixes - Disable automatic toolchain switching for `language: golang`.     - #3304 PR by @AleksaC.     - #3300 issue by @AleksaC.     - #3149 issue by @nijel. - Fix `language: r` installation when initiated by RStudio.     - #3389 PR by @lorenzwalthert.     - #3385 issue by @lorenzwalthert. |
| `v4.0.1` | 2024-10-08 | Low | ### Fixes - Fix `pre-commit migrate-config` for unquoted deprecated stages names with   purelib `pyyaml`.     - #3324 PR by @asottile.     - pre-commit-ci/issues#234 issue by @lorenzwalthert. |
| `v4.0.0` | 2024-10-05 | Low | ### Features - Improve `pre-commit migrate-config` to handle more yaml formats.     - #3301 PR by @asottile. - Handle `stages` deprecation in `pre-commit migrate-config`.     - #3302 PR by @asottile.     - #2732 issue by @asottile. - Upgrade `ruby-build`.     - #3199 PR by @ThisGuyCodes. - Add "sensible regex" warnings to `repo: meta`.     - #3311 PR by @asottile. - Add warnings for deprecated `stages` (`commit` -> `pre-commit`, `push` ->   `pre-push`, `merge-commit` -> `pre-merge-com |

## Citation

- HTML: https://www.freshcrate.ai/projects/pre-commit
- Markdown: https://www.freshcrate.ai/projects/pre-commit.md
- Dependencies JSON: https://www.freshcrate.ai/api/projects/pre-commit/deps

_Generated by freshcrate.ai. Indexes pypi releases for AI-agent ecosystem packages._
