1
0
mirror of https://github.com/j178/prek.git synced 2026-04-03 17:34:03 +02:00

21 Commits

Author SHA1 Message Date
Jo
ec2c03f7c2 Document compatibility with pre-commit (#1767) 2026-03-10 13:06:27 +08:00
Shaan Majid
4525825ea8 docs: remove todo.md (#1501)
- Remove `todo.md` as remaining items have been addressed or documented
elsewhere.
- Move note to `diff.md` that `pre-commit hazmat` subcommand (v4.5.0) is
not implemented.
2026-01-31 22:34:14 +08:00
Shaan Majid
f5262b6b2c docs: fix HTML anchors, grammar, capitalization, and add missing tracking issues (#1448) 2026-01-22 02:06:13 +08:00
Jo
52c20ab065 Document language support details (#1380) 2026-01-17 17:48:11 +08:00
Copilot
c48699a526 Document UV environment variable inheritance in prek (#1339)
* Initial plan

* Document UV environment variable impact in diff.md

Co-authored-by: j178 <10510431+j178@users.noreply.github.com>

* Use mkdocs-material warning callout for UV environment variables

Co-authored-by: j178 <10510431+j178@users.noreply.github.com>

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: j178 <10510431+j178@users.noreply.github.com>
2026-01-12 20:47:58 +08:00
Branch Vincent
d0c33b1833 Support apple's container for docker lang (#1306)
* Support apple's `container` for docker lang

* Tweak

---------

Co-authored-by: Jo <10510431+j178@users.noreply.github.com>
2026-01-07 16:09:05 +08:00
Jo
1c9d1f5618 Implement priority based parallel execution (#1232)
* Support priority-based parallel hook execution

* .

* .

* .

* .

* .

* Implement `priority` based parallel exeuction

* Reduce repeated code

* Add progress for processing files

* Improve sytling

* Tweak UI

* Fix UI

* Update snaps

* Update docs

* Add a test

* Update proposal

* Update crates/prek/src/config.rs

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Apply review feedbacks

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-12-20 12:09:42 +08:00
Jo
72f4c5a59a Prefer tag creation timestamp in --cooldown-days (#1221)
Use `git for-each-ref --sort=-creatordate --format='%(refname:lstrip=2) %(creatordate:unix)' refs/tags` to get a list of tags along with their timestamps.
`creatordate` uses the tag’s creation time if it’s an annotated tag, and if it’s a lightweight tag, it falls back to the commit’s timestamp.
2025-12-13 19:19:55 +08:00
Louis Maddox
2ad3a70f07 Support--cooldown-days in prek auto-update (#1172)
* feat: implement cooldown (default: 1 day)

* refactor: make update_repo a coordinator function

* fix: fallback to search all tags when candidate fails

* perf: batch the tag commit date iteration into one call

* Simplify logic

* Add tests

* Change `--cooldown-days` default to 0, keep backward compability

* Remove `cooldown_days` from config

---------

Co-authored-by: Jo <10510431+j178@users.noreply.github.com>
2025-12-12 13:30:30 +08:00
Louis Maddox
dad650b965 rust: add support for finding packages in virtual workspaces (#1180)
* fix(rust): find packages in virtual workspaces

* chore(deps): add cargo_metadata

* refactor: use cargo_metadata instead of DIY approach

* revert: do not change prek's own typos hook

* Sort deps

* Mention in `diff.md`

* Minor tweaks

---------

Co-authored-by: Jo <10510431+j178@users.noreply.github.com>
2025-12-04 17:18:36 +08:00
Jo
3e88436974 Add support repo: builtin (#1118)
* Add support `repo: builtin`

* Add docs

* Fixes

* Skip install for builtin hooks
2025-11-19 17:29:14 +08:00
Jo
7b608841b0 Mention PREK_CONTAINER_RUNTIME in diff.md (#1043) 2025-11-07 17:24:15 +08:00
is-alnilam
d9baf0a5f1 Add Ruby support (no download support yet) (#993)
* Add Ruby support (no download support yet)

Currently only pre-existing Rubies are used, although the code will
search for and consider multiple versions. This allows a hook to require
3.4.7 when the default system Ruby is 3.4.6, but RVM (or a similar tool)
has installed 3.4.7. If a suitable Ruby cannot be found, the user is
prompted to install one manually and re-run.

Hooks get an isolated GEM_HOME, based on the hook repository, any
additional_dependencies, and the interpreter version/path. Any Ruby
upgrade would therefore re-install the gems to ensure that stale
versions aren't used. Repository gem dependencies are installed based on
the included gemspec files, combined with the additional_dependencies
field.

* Add pins for CI 'install Ruby' action

* Update setup-ruby pin

* Tweak version parsing

* Tweak env vars

---------

Co-authored-by: Jo <10510431+j178@users.noreply.github.com>
2025-11-03 19:12:25 +08:00
Jo
7551dab631 Update docs about uv in prek (#810) 2025-09-28 17:20:10 +08:00
Jo
04bb76fcb4 Add prek cache dir, move prek gc and prek clean under prek cache (#795)
`prek gc` and `prek clean` are still available but hidden.
2025-09-25 13:36:41 +08:00
Jo
65c29da7b6 Update some docs (#745)
* .

* Improve some docs
2025-09-15 15:59:13 +08:00
arielle
240063c4af Fix typo in language-version to language_version (#727)
Checking the pre-commit documentation and the source code of prek will reveal that this is named language_version rather than language-version. 

It's a tiny nit but a little confusing otherwise
2025-09-14 13:29:16 +08:00
Jo
bc1b423a94 Bring back .pre-commit-config.yml support (#676)
* Bring back `.pre-commit-config.yml` support

* Fix snaps
2025-09-08 19:39:46 +08:00
Hugo van Kemenade
6cd06f5f8a Docs: .pre-commit-config.yml support has been removed (#630) 2025-09-06 20:19:36 +08:00
Jo
5cbdeecccb Publish docs (#627) 2025-09-06 18:08:56 +08:00
Jo
8d644ef337 Fix config not staged relative filename display (#585)
* .

* Fix config not staged relative filename display
2025-09-06 16:44:22 +08:00