Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork34k
Closed
Description
Feature or enhancement
Proposal:
First, I hope this is the correct issue template. If not, please let me know, and I can resubmit the proposal using the proper template.
prek is a "reimagined version of pre-commit, [...] designed to be a faster, dependency-free and drop-in alternative".
It has already been adopted by major projects from Apache, FastAPI, and Django (seeprek/Who is using prek?).
Running prek against the entire CPython codebase yields a speedup of almost 2.5x without a cache and 1.25x with a warm cache.
hyperfine --warmup 2 --runs 5 \ --prepare"prek cache clean""prek run --all-files" \ --prepare"pre-commit clean""pre-commit run --all-files"Benchmark 1: prek run --all-files Time (mean ± σ): 19.835 s ± 0.290 s [User: 50.857 s, System: 6.248 s] Range (min … max): 19.527 s … 20.201 s 5 runsBenchmark 2: pre-commit run --all-files Time (mean ± σ): 48.944 s ± 0.448 s [User: 76.063 s, System: 6.096 s] Range (min … max): 48.522 s … 49.681 s 5 runsSummary prek run --all-files ran 2.47 ± 0.04times faster than pre-commit run --all-files
hyperfine --warmup 2 --runs 5 \"prek run --all-files" \"pre-commit run --all-files"Benchmark 1: prek run --all-files Time (mean ± σ): 6.763 s ± 0.124 s [User: 35.990 s, System: 2.134 s] Range (min … max): 6.589 s … 6.900 s 5 runsBenchmark 2: pre-commit run --all-files Time (mean ± σ): 8.537 s ± 0.048 s [User: 43.797 s, System: 1.903 s] Range (min … max): 8.484 s … 8.608 s 5 runsSummary prek run --all-files ran 1.26 ± 0.02times faster than pre-commit run --all-files
Has this already been discussed elsewhere?
This is a minor feature, which does not need previous discussion elsewhere
Links to previous discussion of this feature:
No response