Skip to content

docs: replace pre-commit by prek in the contrib instructions#490

Merged
joanise merged 1 commit into
mainfrom
dev.ej/prek
May 27, 2026
Merged

docs: replace pre-commit by prek in the contrib instructions#490
joanise merged 1 commit into
mainfrom
dev.ej/prek

Conversation

@joanise
Copy link
Copy Markdown
Member

@joanise joanise commented May 7, 2026

PR Goal?

Replace pre-commit by prek https://prek.j178.dev/

  • prek uses uv to install hooks much faster
  • built in Rust, with the explicit intent to be fast
  • it can run the hooks in parallel when multiple files are affected
  • it's a drop-in replacement requiring no other change than doing prek install instead of pre-commit install

Fixes?

my growing annoyance with pre-commit, and really, just cause all these new rust-based tools actually are nicer. :)

I've actually been using prek for months now, but I didn't to impose it on anyone. When I mentioned it to Samuel, he chided me for now sharing the joy, so this PR is me finally doing that sharing.

It's not a huge difference, but it's still enough difference I found it worth switching, especially given how trivial it is to switch.

How to test?

Install prek:

  • redo pip install -e ".[dev]", or just do pip install prek, or even uv tool install prek` for a global install

Remove the pre-commit hook if you installed it before

rm .git/hooks/pre-commit

(Re-)install the hook:

prek install

Now commit some changes. prek will have to install everything in .pre-commit-config.yaml fresh, so the first time will be slow, though not nearly as slow as when using pre-commit, and subsequent times will be nice and fast.

Confidence?

high

Version change?

no

Related PRs?

EveryVoiceTTS/EveryVoice#798
ReadAlongs/Studio#303

@codecov
Copy link
Copy Markdown

codecov Bot commented May 7, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 7, 2026

CLI load time: 0:00.08
Pull Request HEAD: d272b48cb312b4b5afd6de36e328230f5d464d01
Imports that take more than 0.1 s:
import time: self [us] | cumulative | imported package

Copy link
Copy Markdown
Collaborator

@roedoejet roedoejet left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm, thanks for adding!

@joanise joanise merged commit ae6e45f into main May 27, 2026
7 checks passed
@joanise joanise deleted the dev.ej/prek branch May 27, 2026 20:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants