Skip to main content

pre-commit-uv

PyPI PyPI - Implementation PyPI - Python Version Downloads PyPI - License check

Use uv to create virtual environments and install packages for pre-commit.

Changelog

Contributing

Installation

With pipx:

pipx install pre-commit
pipx inject pre-commit pre-commit-uv

With uv:

uv tool install pre-commit --with pre-commit-uv --force-reinstall

Why?

pre-commit-uv uses uv to create and seed hook environments. Caching the pre-commit directory avoids this work on later runs, but the first install still needs it. This benchmark used this project's hooks with a warm uv cache:

❯ hyperfine  'pre-commit install-hooks' 'pre-commit-uv install-hooks'
Benchmark 1: pre-commit install-hooks
  Time (mean ± σ):     54.132 s ±  8.827 s    [User: 15.424 s, System: 9.359 s]
  Range (min … max):   45.972 s … 66.506 s    10 runs

Benchmark 2: pre-commit-uv install-hooks
  Time (mean ± σ):     41.695 s ±  7.395 s    [User: 7.614 s, System: 6.133 s]
  Range (min … max):   32.198 s … 58.467 s    10 runs

Summary
  pre-commit-uv install-hooks ran 1.30 ± 0.31 times faster than pre-commit install-hooks

Configuration

Once installed, pre-commit-uv uses uv by default. Set DISABLE_PRE_COMMIT_UV_PATCH to use pre-commit's normal installation path instead.

The patch loads when the process appears to be running pre-commit. If detection misses a call, set FORCE_PRE_COMMIT_UV_PATCH and report the value of sys.argv in an issue. DISABLE_PRE_COMMIT_UV_PATCH takes precedence when both variables are set.

Metadata

Release files for pre-commit-uv 4.4.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pre-commit-uv 4.4.1
File Size Uploaded Provenance Actions
pre_commit_uv-4.4.1.tar.gz 11.5 kB With provenance Details for pre_commit_uv-4.4.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for pre-commit-uv 4.4.1
File Interpreter ABI Platform Actions
pre_commit_uv-4.4.1-py3-none-any.whl Python 3 none any Details for pre_commit_uv-4.4.1-py3-none-any.whl

Total release size: 17.0 kB

Release files / pre_commit_uv-4.4.1.tar.gz

Download URL pre_commit_uv-4.4.1.tar.gz
Size 11.5 kB
Tags Source
SHA-256 checksum
How to use checksums
e59ce77dc49d0b0481efbc97293c4fe235ddeb5ab5028c8a9e20e6cb5cce9756
BLAKE2b-256 checksum
How to use checksums
98622791f79c1cf48993ef0bee64e0636c9e86212467cdd3d0486a21d51f2438
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 27, 2026.

Transparency log

Release files / pre_commit_uv-4.4.1-py3-none-any.whl

Download URL pre_commit_uv-4.4.1-py3-none-any.whl
Size 5.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
5c387a044d74c215090835c97bd41e469659025c6551ddc73f9f8e7d8d323c00
BLAKE2b-256 checksum
How to use checksums
463dca2481fa9d5fd3c99e88be090dbadf5320dda8ddb80df13931e832ea46ef
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 27, 2026.

Transparency log

Security for pre-commit-uv 4.4.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

All 2 files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for pre_commit_uv-4.4.1.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 27, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page