pre-commit is a framework to run hooks written in many languages, and it manages
the language toolchain and dependencies for running the hooks.
prek is a reimagined version of pre-commit, built in Rust. It is designed to be
a faster, dependency-free and drop-in alternative for it, while also providing
some additional long-requested features.
Features:
- A single binary with no dependencies, does not require Python or any other
runtime.
- Faster than pre-commit and more efficient in disk space usage.
- Fully compatible with the original pre-commit configurations and hooks.
- Built-in support for monorepos (i.e. workspace mode).
- Integration with uv for managing Python virtual environments and dependencies.
- Improved toolchain installations for Python, Node.js, Bun, Go, Rust and Ruby,
shared between hooks.
- Built-in Rust-native implementation of some common hooks.
NOTE: If this package has multiple flavors (see below), then use one of them instead of the name specified above. NOTE: This is a Python port. Instead of py312-prek listed in the above command, you can pick from the names under the Packages section.
devel/py-prek: Add py-prek 0.3.11
pre-commit is a framework to run hooks written in many languages, and it manages
the language toolchain and dependencies for running the hooks.
prek is a reimagined version of pre-commit, built in Rust. It is designed to be
a faster, dependency-free and drop-in alternative for it, while also providing
some additional long-requested features.
Features:
- A single binary with no dependencies, does not require Python or any other
runtime.
- Faster than pre-commit and more efficient in disk space usage.
- Fully compatible with the original pre-commit configurations and hooks.
- Built-in support for monorepos (i.e. workspace mode).
- Integration with uv for managing Python virtual environments and dependencies.
- Improved toolchain installations for Python, Node.js, Bun, Go, Rust and Ruby,
shared between hooks.
- Built-in Rust-native implementation of some common hooks.