From f8eda3bb32b700e6927d3553cda7e9b2ca2153f3 Mon Sep 17 00:00:00 2001 From: Fredrik Ekre Date: Fri, 1 Nov 2024 15:36:18 +0100 Subject: [PATCH 01/68] Documentation for julia hooks See pre-commit PR: https://github.com/pre-commit/pre-commit/pull/3348 --- sections/new-hooks.md | 39 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 39 insertions(+) diff --git a/sections/new-hooks.md b/sections/new-hooks.md index a1f5604e..70699666 100644 --- a/sections/new-hooks.md +++ b/sections/new-hooks.md @@ -330,6 +330,45 @@ This language supports `additional_dependencies` so it can be used as a __Support:__ haskell hooks are known to work on any system which has `cabal` installed. It has been tested on linux, macOS, and windows. +### julia + +_new in 4.1.0_ + +For configuring julia hooks, your [`entry`](#hooks-entry) should be a path to a julia source +file relative to the hook repository (optionally with arguments). + +Hooks run in an isolated package environment defined by a `Project.toml` file (optionally +with a `Manifest.toml` file) in the hook repository. If no `Project.toml` file is found the +hook is run in an empty environment. + +Julia hooks support [`additional_dependencies`](#config-additional_dependencies) which can +be used to augment, or override, the existing environment in the hooks repository. This also +means that julia can be used as a `repo: local` hook. `additional_dependencies` are passed +to `pkg> add` and should be specified using +[Pkg REPL mode syntax](https://pkgdocs.julialang.org/v1/repl/#repl-add). + +Examples: + +```yaml +- id: foo-without-args + name: ... + language: julia + entry: bin/foo.jl +- id: bar-with-args + name: ... + language: julia + entry: bin/bar.jl --arg1 --arg2 +- id: baz-with-extra-deps + name: ... + language: julia + entry: bin/baz.jl + additional_dependencies: + - 'ExtraDepA@1' + - 'ExtraDepB@2.4' +``` + +__Support:__ julia hooks are known to work on any system which has `julia` installed. + ### lua Lua hooks are installed with the version of Lua that is used by Luarocks. From 5da39af30602984cfd50034e071843ec4f11910d Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 9 Dec 2024 22:35:03 +0000 Subject: [PATCH 02/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/biomejs/pre-commit: v0.5.0 → v0.6.0](https://github.com/biomejs/pre-commit/compare/v0.5.0...v0.6.0) --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index f95b7cdf..7aac2d2a 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -37,7 +37,7 @@ repos: hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit - rev: v0.5.0 + rev: v0.6.0 hooks: - id: biome-check additional_dependencies: ["@biomejs/biome@1.8.1"] From 8ac3aaea32eeec8361075369918a3e45cb92d699 Mon Sep 17 00:00:00 2001 From: Anthony Sottile Date: Mon, 16 Dec 2024 20:48:07 -0500 Subject: [PATCH 03/68] undo language_version: lts --- .pre-commit-config.yaml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 7aac2d2a..bd57334e 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -41,3 +41,5 @@ repos: hooks: - id: biome-check additional_dependencies: ["@biomejs/biome@1.8.1"] + # https://github.com/biomejs/pre-commit/issues/16 + language_version: default From c9b579ca70f167fc5107c743bf9a20bc98f3eaa1 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 23 Dec 2024 22:45:31 +0000 Subject: [PATCH 04/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/asottile/pyupgrade: v3.19.0 → v3.19.1](https://github.com/asottile/pyupgrade/compare/v3.19.0...v3.19.1) - [github.com/pre-commit/mirrors-mypy: v1.13.0 → v1.14.0](https://github.com/pre-commit/mirrors-mypy/compare/v1.13.0...v1.14.0) - [github.com/biomejs/pre-commit: v0.6.0 → v0.6.1](https://github.com/biomejs/pre-commit/compare/v0.6.0...v0.6.1) --- .pre-commit-config.yaml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index bd57334e..966a5a18 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -20,7 +20,7 @@ repos: hooks: - id: add-trailing-comma - repo: https://github.com/asottile/pyupgrade - rev: v3.19.0 + rev: v3.19.1 hooks: - id: pyupgrade args: [--py39-plus] @@ -33,11 +33,11 @@ repos: hooks: - id: flake8 - repo: https://github.com/pre-commit/mirrors-mypy - rev: v1.13.0 + rev: v1.14.0 hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit - rev: v0.6.0 + rev: v0.6.1 hooks: - id: biome-check additional_dependencies: ["@biomejs/biome@1.8.1"] From 7cbbecab199c4abfe8eda1eaf0398677f82fbc26 Mon Sep 17 00:00:00 2001 From: Anthony Sottile Date: Mon, 23 Dec 2024 21:15:26 -0500 Subject: [PATCH 05/68] remove `language_version` workaround --- .pre-commit-config.yaml | 2 -- 1 file changed, 2 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 966a5a18..fa22c789 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -41,5 +41,3 @@ repos: hooks: - id: biome-check additional_dependencies: ["@biomejs/biome@1.8.1"] - # https://github.com/biomejs/pre-commit/issues/16 - language_version: default From 4b53cb42cd8c0d22ef4204080e93031c8ddcb12e Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 6 Jan 2025 23:30:25 +0000 Subject: [PATCH 06/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/pre-commit/mirrors-mypy: v1.14.0 → v1.14.1](https://github.com/pre-commit/mirrors-mypy/compare/v1.14.0...v1.14.1) --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index fa22c789..7380f6b8 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -33,7 +33,7 @@ repos: hooks: - id: flake8 - repo: https://github.com/pre-commit/mirrors-mypy - rev: v1.14.0 + rev: v1.14.1 hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit From 75e7d099e5559d6d89e2afffce34970e951c6cdd Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 20 Jan 2025 22:29:50 +0000 Subject: [PATCH 07/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/hhatto/autopep8: v2.3.1 → v2.3.2](https://github.com/hhatto/autopep8/compare/v2.3.1...v2.3.2) --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 7380f6b8..1ef5586f 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -25,7 +25,7 @@ repos: - id: pyupgrade args: [--py39-plus] - repo: https://github.com/hhatto/autopep8 - rev: v2.3.1 + rev: v2.3.2 hooks: - id: autopep8 - repo: https://github.com/PyCQA/flake8 From f2412b98716212cf3a53c1c27e2bd7a8d0a13ee6 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 10 Feb 2025 22:44:03 +0000 Subject: [PATCH 08/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/pre-commit/mirrors-mypy: v1.14.1 → v1.15.0](https://github.com/pre-commit/mirrors-mypy/compare/v1.14.1...v1.15.0) --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 1ef5586f..c9640e61 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -33,7 +33,7 @@ repos: hooks: - id: flake8 - repo: https://github.com/pre-commit/mirrors-mypy - rev: v1.14.1 + rev: v1.15.0 hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit From 5f40d02e70c202dbfc5d73c2516af728e26c7fec Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 17 Feb 2025 21:07:34 +0000 Subject: [PATCH 09/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/PyCQA/flake8: 7.1.1 → 7.1.2](https://github.com/PyCQA/flake8/compare/7.1.1...7.1.2) --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index c9640e61..6153149e 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -29,7 +29,7 @@ repos: hooks: - id: autopep8 - repo: https://github.com/PyCQA/flake8 - rev: 7.1.1 + rev: 7.1.2 hooks: - id: flake8 - repo: https://github.com/pre-commit/mirrors-mypy From d4fe6de0f4c7fdaf0024b144e439b6ca98916726 Mon Sep 17 00:00:00 2001 From: David Xia Date: Fri, 7 Feb 2025 08:00:34 -0500 Subject: [PATCH 10/68] docs: add DavidAnson/markdownlint-cli2 to hooks page The current Markdownlint hook is in Ruby. Mention a popular Node-based one as well. Signed-off-by: David Xia --- sections/hooks.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/sections/hooks.md b/sections/hooks.md index 828e9db9..8796a4da 100644 --- a/sections/hooks.md +++ b/sections/hooks.md @@ -75,13 +75,15 @@ for text / docs / prose: - [crate-ci/typos]: find and fix common typographical errors - [thlorenz/doctoc]: generate a table-of-contents in markdown files - [amperser/proselint]: A linter for prose. -- [markdownlint/markdownlint]: a Markdown lint tool +- [markdownlint/markdownlint]: a Markdown lint tool in Ruby +- [DavidAnson/markdownlint-cli2]: a Markdown lint tool in Node - [codespell-project/codespell]: check code for common misspellings [crate-ci/typos]: https://github.com/crate-ci/typos [thlorenz/doctoc]: https://github.com/thlorenz/doctoc [amperser/proselint]: https://github.com/amperser/proselint [markdownlint/markdownlint]: https://github.com/markdownlint/markdownlint +[DavidAnson/markdownlint-cli2]: https://github.com/DavidAnson/markdownlint-cli2 [codespell-project/codespell]: https://github.com/codespell-project/codespell for linting commit messages: From 96caf22c7466eb215a614389a51908ca0cdac2d9 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 24 Feb 2025 19:44:47 +0000 Subject: [PATCH 11/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/biomejs/pre-commit: v0.6.1 → v1.9.4](https://github.com/biomejs/pre-commit/compare/v0.6.1...v1.9.4) --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 6153149e..12005c89 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -37,7 +37,7 @@ repos: hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit - rev: v0.6.1 + rev: v1.9.4 hooks: - id: biome-check additional_dependencies: ["@biomejs/biome@1.8.1"] From 50954289ede630b82d3fbf128a63a433b28379ef Mon Sep 17 00:00:00 2001 From: Maksym Vlasov Date: Mon, 17 Mar 2025 14:26:36 +0200 Subject: [PATCH 12/68] docs: Fix missleading link It was copy-pasted from previous link for shell, and currently point to wrong search result. This PR fix that. --- sections/hooks.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sections/hooks.md b/sections/hooks.md index 8796a4da..40d17c36 100644 --- a/sections/hooks.md +++ b/sections/hooks.md @@ -138,7 +138,7 @@ for example, here's some searches you may find useful using [sourcegraph]: - hooks which run on python files: [`file:^\.pre-commit-hooks\.yaml$ "types: [python]"`](https://sourcegraph.com/search?q=context:global+file:^\.pre-commit-hooks\.yaml%24+%22types:+[python]%22) - hooks which run on shell files: [`file:^\.pre-commit-hooks\.yaml$ "types: [shell]"`](https://sourcegraph.com/search?q=context:global+file:^\.pre-commit-hooks\.yaml%24+"types:+[shell]") -- pre-commit configurations in popular projects: [`file:^\.pre-commit-config\.yaml$`](https://sourcegraph.com/search?q=context:global+file:^\.pre-commit-hooks\.yaml%24+"types:+[shell]") +- pre-commit configurations in popular projects: [`file:^\.pre-commit-config\.yaml$`](https://sourcegraph.com/search?q=context:global+file:^\.pre-commit-hooks\.yaml") [sourcegraph]: https://sourcegraph.com/search From 8be946894b24903ac7e2bfc1484c8b6315259791 Mon Sep 17 00:00:00 2001 From: Maksym Vlasov Date: Fri, 21 Mar 2025 00:32:36 +0200 Subject: [PATCH 13/68] docs: Fix broken link --- sections/hooks.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sections/hooks.md b/sections/hooks.md index 40d17c36..1a97d5dc 100644 --- a/sections/hooks.md +++ b/sections/hooks.md @@ -138,7 +138,7 @@ for example, here's some searches you may find useful using [sourcegraph]: - hooks which run on python files: [`file:^\.pre-commit-hooks\.yaml$ "types: [python]"`](https://sourcegraph.com/search?q=context:global+file:^\.pre-commit-hooks\.yaml%24+%22types:+[python]%22) - hooks which run on shell files: [`file:^\.pre-commit-hooks\.yaml$ "types: [shell]"`](https://sourcegraph.com/search?q=context:global+file:^\.pre-commit-hooks\.yaml%24+"types:+[shell]") -- pre-commit configurations in popular projects: [`file:^\.pre-commit-config\.yaml$`](https://sourcegraph.com/search?q=context:global+file:^\.pre-commit-hooks\.yaml") +- pre-commit configurations in popular projects: [`file:^\.pre-commit-config\.yaml$`](https://sourcegraph.com/search?q=context:global+file:^\.pre-commit-hooks\.yaml) [sourcegraph]: https://sourcegraph.com/search From 7cd4f25b1cea23ef0a33bfff040e55e339611807 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 31 Mar 2025 19:43:56 +0000 Subject: [PATCH 14/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/PyCQA/flake8: 7.1.2 → 7.2.0](https://github.com/PyCQA/flake8/compare/7.1.2...7.2.0) - [github.com/biomejs/pre-commit: v1.9.4 → v2.0.0-beta.1](https://github.com/biomejs/pre-commit/compare/v1.9.4...v2.0.0-beta.1) --- .pre-commit-config.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 12005c89..7fa55780 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -29,7 +29,7 @@ repos: hooks: - id: autopep8 - repo: https://github.com/PyCQA/flake8 - rev: 7.1.2 + rev: 7.2.0 hooks: - id: flake8 - repo: https://github.com/pre-commit/mirrors-mypy @@ -37,7 +37,7 @@ repos: hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit - rev: v1.9.4 + rev: v2.0.0-beta.1 hooks: - id: biome-check additional_dependencies: ["@biomejs/biome@1.8.1"] From 113d1134cdbc5089e8ecfc60c1135cd16371de93 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 5 May 2025 19:56:04 +0000 Subject: [PATCH 15/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/biomejs/pre-commit: v2.0.0-beta.1 → v2.0.0-beta.2](https://github.com/biomejs/pre-commit/compare/v2.0.0-beta.1...v2.0.0-beta.2) --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 7fa55780..8c0297c5 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -37,7 +37,7 @@ repos: hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit - rev: v2.0.0-beta.1 + rev: v2.0.0-beta.2 hooks: - id: biome-check additional_dependencies: ["@biomejs/biome@1.8.1"] From c526c9ad16b5d3c8b8e21f9ac2cf5613fab1d522 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 12 May 2025 19:43:22 +0000 Subject: [PATCH 16/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/biomejs/pre-commit: v2.0.0-beta.2 → v2.0.0-beta.3](https://github.com/biomejs/pre-commit/compare/v2.0.0-beta.2...v2.0.0-beta.3) --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 8c0297c5..a6feae51 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -37,7 +37,7 @@ repos: hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit - rev: v2.0.0-beta.2 + rev: v2.0.0-beta.3 hooks: - id: biome-check additional_dependencies: ["@biomejs/biome@1.8.1"] From 6749eb002979f118b725d9a7c31bc62f7a367514 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 19 May 2025 19:47:46 +0000 Subject: [PATCH 17/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/biomejs/pre-commit: v2.0.0-beta.3 → v2.0.0-beta.4](https://github.com/biomejs/pre-commit/compare/v2.0.0-beta.3...v2.0.0-beta.4) --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index a6feae51..8f75b88e 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -37,7 +37,7 @@ repos: hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit - rev: v2.0.0-beta.3 + rev: v2.0.0-beta.4 hooks: - id: biome-check additional_dependencies: ["@biomejs/biome@1.8.1"] From 788d0a616db94946945792759d1ca70c3072d7cf Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 26 May 2025 19:45:49 +0000 Subject: [PATCH 18/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/asottile/reorder-python-imports: v3.14.0 → v3.15.0](https://github.com/asottile/reorder-python-imports/compare/v3.14.0...v3.15.0) - [github.com/asottile/add-trailing-comma: v3.1.0 → v3.2.0](https://github.com/asottile/add-trailing-comma/compare/v3.1.0...v3.2.0) - [github.com/asottile/pyupgrade: v3.19.1 → v3.20.0](https://github.com/asottile/pyupgrade/compare/v3.19.1...v3.20.0) - [github.com/biomejs/pre-commit: v2.0.0-beta.4 → v2.0.0-beta.5](https://github.com/biomejs/pre-commit/compare/v2.0.0-beta.4...v2.0.0-beta.5) --- .pre-commit-config.yaml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 8f75b88e..49b7d7de 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -10,17 +10,17 @@ repos: - id: name-tests-test - id: requirements-txt-fixer - repo: https://github.com/asottile/reorder-python-imports - rev: v3.14.0 + rev: v3.15.0 hooks: - id: reorder-python-imports args: [--py39-plus, --add-import, 'from __future__ import annotations'] - id: reorder-python-imports - repo: https://github.com/asottile/add-trailing-comma - rev: v3.1.0 + rev: v3.2.0 hooks: - id: add-trailing-comma - repo: https://github.com/asottile/pyupgrade - rev: v3.19.1 + rev: v3.20.0 hooks: - id: pyupgrade args: [--py39-plus] @@ -37,7 +37,7 @@ repos: hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit - rev: v2.0.0-beta.4 + rev: v2.0.0-beta.5 hooks: - id: biome-check additional_dependencies: ["@biomejs/biome@1.8.1"] From 4152f35c884b779c41dc98fefcd00854476b950a Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 2 Jun 2025 19:57:11 +0000 Subject: [PATCH 19/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/pre-commit/mirrors-mypy: v1.15.0 → v1.16.0](https://github.com/pre-commit/mirrors-mypy/compare/v1.15.0...v1.16.0) --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 49b7d7de..65df650e 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -33,7 +33,7 @@ repos: hooks: - id: flake8 - repo: https://github.com/pre-commit/mirrors-mypy - rev: v1.15.0 + rev: v1.16.0 hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit From afe5d18e313b76e288440e0542bf2ea67ba712c5 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 23 Jun 2025 19:55:26 +0000 Subject: [PATCH 20/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/PyCQA/flake8: 7.2.0 → 7.3.0](https://github.com/PyCQA/flake8/compare/7.2.0...7.3.0) - [github.com/pre-commit/mirrors-mypy: v1.16.0 → v1.16.1](https://github.com/pre-commit/mirrors-mypy/compare/v1.16.0...v1.16.1) - [github.com/biomejs/pre-commit: v2.0.0-beta.5 → v2.0.2](https://github.com/biomejs/pre-commit/compare/v2.0.0-beta.5...v2.0.2) --- .pre-commit-config.yaml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 65df650e..8f123d07 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -29,15 +29,15 @@ repos: hooks: - id: autopep8 - repo: https://github.com/PyCQA/flake8 - rev: 7.2.0 + rev: 7.3.0 hooks: - id: flake8 - repo: https://github.com/pre-commit/mirrors-mypy - rev: v1.16.0 + rev: v1.16.1 hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit - rev: v2.0.0-beta.5 + rev: v2.0.2 hooks: - id: biome-check additional_dependencies: ["@biomejs/biome@1.8.1"] From 505020bf91edf43eef1f5efa70c7e40181ca081a Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 30 Jun 2025 19:40:10 +0000 Subject: [PATCH 21/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/biomejs/pre-commit: v2.0.2 → v2.0.6](https://github.com/biomejs/pre-commit/compare/v2.0.2...v2.0.6) --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 8f123d07..60c3474c 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -37,7 +37,7 @@ repos: hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit - rev: v2.0.2 + rev: v2.0.6 hooks: - id: biome-check additional_dependencies: ["@biomejs/biome@1.8.1"] From 0e1a4fb3d0a2b0665bfc5bae24c97dd48afdc29f Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 21 Jul 2025 20:02:26 +0000 Subject: [PATCH 22/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/pre-commit/mirrors-mypy: v1.16.1 → v1.17.0](https://github.com/pre-commit/mirrors-mypy/compare/v1.16.1...v1.17.0) - [github.com/biomejs/pre-commit: v2.0.6 → v2.1.2](https://github.com/biomejs/pre-commit/compare/v2.0.6...v2.1.2) --- .pre-commit-config.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 60c3474c..565bbce4 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -33,11 +33,11 @@ repos: hooks: - id: flake8 - repo: https://github.com/pre-commit/mirrors-mypy - rev: v1.16.1 + rev: v1.17.0 hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit - rev: v2.0.6 + rev: v2.1.2 hooks: - id: biome-check additional_dependencies: ["@biomejs/biome@1.8.1"] From 8e6c0cf9125c64b6918365c67abb8f1a3028d2d3 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 4 Aug 2025 20:31:37 +0000 Subject: [PATCH 23/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/pre-commit/mirrors-mypy: v1.17.0 → v1.17.1](https://github.com/pre-commit/mirrors-mypy/compare/v1.17.0...v1.17.1) - [github.com/biomejs/pre-commit: v2.1.2 → v2.1.3](https://github.com/biomejs/pre-commit/compare/v2.1.2...v2.1.3) --- .pre-commit-config.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 565bbce4..06118d83 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -33,11 +33,11 @@ repos: hooks: - id: flake8 - repo: https://github.com/pre-commit/mirrors-mypy - rev: v1.17.0 + rev: v1.17.1 hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit - rev: v2.1.2 + rev: v2.1.3 hooks: - id: biome-check additional_dependencies: ["@biomejs/biome@1.8.1"] From 262eef89d2ce2cc0ec8e023f9088768735ec04d3 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 11 Aug 2025 20:46:41 +0000 Subject: [PATCH 24/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/pre-commit/pre-commit-hooks: v5.0.0 → v6.0.0](https://github.com/pre-commit/pre-commit-hooks/compare/v5.0.0...v6.0.0) - [github.com/biomejs/pre-commit: v2.1.3 → v2.1.4](https://github.com/biomejs/pre-commit/compare/v2.1.3...v2.1.4) --- .pre-commit-config.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 06118d83..9f306963 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -1,6 +1,6 @@ repos: - repo: https://github.com/pre-commit/pre-commit-hooks - rev: v5.0.0 + rev: v6.0.0 hooks: - id: trailing-whitespace - id: end-of-file-fixer @@ -37,7 +37,7 @@ repos: hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit - rev: v2.1.3 + rev: v2.1.4 hooks: - id: biome-check additional_dependencies: ["@biomejs/biome@1.8.1"] From 30335c6efa212c75b1d93903eac5609e7bf8bb90 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 18 Aug 2025 20:20:02 +0000 Subject: [PATCH 25/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/biomejs/pre-commit: v2.1.4 → v2.2.0](https://github.com/biomejs/pre-commit/compare/v2.1.4...v2.2.0) --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 9f306963..2a4833b2 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -37,7 +37,7 @@ repos: hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit - rev: v2.1.4 + rev: v2.2.0 hooks: - id: biome-check additional_dependencies: ["@biomejs/biome@1.8.1"] From 4a2da412c9cdda77ca028a2c25af45ce6c56b6ce Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 25 Aug 2025 20:10:14 +0000 Subject: [PATCH 26/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/biomejs/pre-commit: v2.2.0 → v2.2.2](https://github.com/biomejs/pre-commit/compare/v2.2.0...v2.2.2) --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 2a4833b2..973105dd 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -37,7 +37,7 @@ repos: hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit - rev: v2.2.0 + rev: v2.2.2 hooks: - id: biome-check additional_dependencies: ["@biomejs/biome@1.8.1"] From 060c74ed5c8cceb802702ab311b246c47d87e16b Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 8 Sep 2025 20:24:27 +0000 Subject: [PATCH 27/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/biomejs/pre-commit: v2.2.2 → v2.2.3](https://github.com/biomejs/pre-commit/compare/v2.2.2...v2.2.3) --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 973105dd..0586c7dc 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -37,7 +37,7 @@ repos: hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit - rev: v2.2.2 + rev: v2.2.3 hooks: - id: biome-check additional_dependencies: ["@biomejs/biome@1.8.1"] From e46b5072a3d271b9e48fc0810822adb87ade8145 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 15 Sep 2025 20:23:56 +0000 Subject: [PATCH 28/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/pre-commit/mirrors-mypy: v1.17.1 → v1.18.1](https://github.com/pre-commit/mirrors-mypy/compare/v1.17.1...v1.18.1) - [github.com/biomejs/pre-commit: v2.2.3 → v2.2.4](https://github.com/biomejs/pre-commit/compare/v2.2.3...v2.2.4) --- .pre-commit-config.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 0586c7dc..ad802039 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -33,11 +33,11 @@ repos: hooks: - id: flake8 - repo: https://github.com/pre-commit/mirrors-mypy - rev: v1.17.1 + rev: v1.18.1 hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit - rev: v2.2.3 + rev: v2.2.4 hooks: - id: biome-check additional_dependencies: ["@biomejs/biome@1.8.1"] From 7e560abc624ac15cafe945791e6f8b1c241bd20c Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 22 Sep 2025 20:44:17 +0000 Subject: [PATCH 29/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/pre-commit/mirrors-mypy: v1.18.1 → v1.18.2](https://github.com/pre-commit/mirrors-mypy/compare/v1.18.1...v1.18.2) --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index ad802039..eabcd2e5 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -33,7 +33,7 @@ repos: hooks: - id: flake8 - repo: https://github.com/pre-commit/mirrors-mypy - rev: v1.18.1 + rev: v1.18.2 hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit From 9bdfa1943323464659d48ad8a91c98dff5c6389f Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 6 Oct 2025 21:25:46 +0000 Subject: [PATCH 30/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/biomejs/pre-commit: v2.2.4 → v2.2.5](https://github.com/biomejs/pre-commit/compare/v2.2.4...v2.2.5) --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index eabcd2e5..b7ff4eca 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -37,7 +37,7 @@ repos: hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit - rev: v2.2.4 + rev: v2.2.5 hooks: - id: biome-check additional_dependencies: ["@biomejs/biome@1.8.1"] From c03eb70f65896db17317e5f089d43135cd7f5c78 Mon Sep 17 00:00:00 2001 From: anthony sottile Date: Thu, 9 Oct 2025 17:46:20 -0400 Subject: [PATCH 31/68] py310+ Committed via https://github.com/asottile/all-repos --- .pre-commit-config.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index eabcd2e5..9b4299ad 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -13,7 +13,7 @@ repos: rev: v3.15.0 hooks: - id: reorder-python-imports - args: [--py39-plus, --add-import, 'from __future__ import annotations'] + args: [--py310-plus, --add-import, 'from __future__ import annotations'] - id: reorder-python-imports - repo: https://github.com/asottile/add-trailing-comma rev: v3.2.0 @@ -23,7 +23,7 @@ repos: rev: v3.20.0 hooks: - id: pyupgrade - args: [--py39-plus] + args: [--py310-plus] - repo: https://github.com/hhatto/autopep8 rev: v2.3.2 hooks: From 5fc98faf8148dadeaf2a95f7b31baea9b15b83fe Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 13 Oct 2025 20:38:51 +0000 Subject: [PATCH 32/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/asottile/reorder-python-imports: v3.15.0 → v3.16.0](https://github.com/asottile/reorder-python-imports/compare/v3.15.0...v3.16.0) - [github.com/asottile/add-trailing-comma: v3.2.0 → v4.0.0](https://github.com/asottile/add-trailing-comma/compare/v3.2.0...v4.0.0) - [github.com/asottile/pyupgrade: v3.20.0 → v3.21.0](https://github.com/asottile/pyupgrade/compare/v3.20.0...v3.21.0) --- .pre-commit-config.yaml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 62fffc4a..d8267d73 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -10,17 +10,17 @@ repos: - id: name-tests-test - id: requirements-txt-fixer - repo: https://github.com/asottile/reorder-python-imports - rev: v3.15.0 + rev: v3.16.0 hooks: - id: reorder-python-imports args: [--py310-plus, --add-import, 'from __future__ import annotations'] - id: reorder-python-imports - repo: https://github.com/asottile/add-trailing-comma - rev: v3.2.0 + rev: v4.0.0 hooks: - id: add-trailing-comma - repo: https://github.com/asottile/pyupgrade - rev: v3.20.0 + rev: v3.21.0 hooks: - id: pyupgrade args: [--py310-plus] From a6b97bafeb862011669fd9b18cea5bb61fb88ed7 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 20 Oct 2025 22:31:21 +0000 Subject: [PATCH 33/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/biomejs/pre-commit: v2.2.5 → v2.2.6](https://github.com/biomejs/pre-commit/compare/v2.2.5...v2.2.6) --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index d8267d73..18774736 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -37,7 +37,7 @@ repos: hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit - rev: v2.2.5 + rev: v2.2.6 hooks: - id: biome-check additional_dependencies: ["@biomejs/biome@1.8.1"] From cf1df5734a9cfdec66613686914d5ffa58da1a92 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 27 Oct 2025 20:19:51 +0000 Subject: [PATCH 34/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/biomejs/pre-commit: v2.2.6 → v2.3.1](https://github.com/biomejs/pre-commit/compare/v2.2.6...v2.3.1) --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 18774736..04f322cf 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -37,7 +37,7 @@ repos: hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit - rev: v2.2.6 + rev: v2.3.1 hooks: - id: biome-check additional_dependencies: ["@biomejs/biome@1.8.1"] From 0e8ffd5dc2b19b3c62048ea513e84acc337f67a1 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 3 Nov 2025 20:45:48 +0000 Subject: [PATCH 35/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/biomejs/pre-commit: v2.3.1 → v2.3.2](https://github.com/biomejs/pre-commit/compare/v2.3.1...v2.3.2) --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 04f322cf..cc9c126b 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -37,7 +37,7 @@ repos: hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit - rev: v2.3.1 + rev: v2.3.2 hooks: - id: biome-check additional_dependencies: ["@biomejs/biome@1.8.1"] From ed4f60b5f538399b765988882eb0cdb61e5df851 Mon Sep 17 00:00:00 2001 From: anthony sottile Date: Sat, 8 Nov 2025 17:11:18 -0500 Subject: [PATCH 36/68] documentation updates for 4.4.0 --- sections/advanced.md | 8 ++++---- sections/hooks.md | 2 +- sections/new-hooks.md | 28 ++++++++++++++++------------ 3 files changed, 21 insertions(+), 17 deletions(-) diff --git a/sections/advanced.md b/sections/advanced.md index 6d1f1f65..b5f7f227 100644 --- a/sections/advanced.md +++ b/sections/advanced.md @@ -272,7 +272,7 @@ For example: hooks: - id: check-requirements name: check requirements files - language: system + language: unsupported entry: python -m scripts.check_requirements --compare files: ^requirements.*\.txt$ ``` @@ -291,7 +291,7 @@ You can configure repository-local hooks by specifying the [`repo`](#repos-repo) sentinel `local`. local hooks can use any language which supports [`additional_dependencies`](#config-additional_dependencies) -or [`docker_image`](#docker_image) / [`fail`](#fail) / [`pygrep`](#pygrep) / [`script`](#script) / [`system`](#system). +or [`docker_image`](#docker_image) / [`fail`](#fail) / [`pygrep`](#pygrep) / [`unsupported`](#unsupported) / [`unsupported_script`](#unsupported_script). This enables you to install things which previously would require a trivial mirror repository. @@ -307,13 +307,13 @@ Here's an example configuration with a few `local` hooks: - id: pylint name: pylint entry: pylint - language: system + language: unsupported types: [python] require_serial: true - id: check-x name: Check X entry: ./bin/check-x.sh - language: script + language: unsupported_script files: \.x$ - id: scss-lint name: scss-lint diff --git a/sections/hooks.md b/sections/hooks.md index 1a97d5dc..27dc128c 100644 --- a/sections/hooks.md +++ b/sections/hooks.md @@ -161,7 +161,7 @@ you may send [a pull request] to expand this list however there are a few requirements you *must* follow or your PR will be closed without comment: - the tool must already be fairly popular (>500 stars) -- the tool must use a managed language (no `system` / `script` / `docker` hooks) +- the tool must use a managed language (no `unsupported` / `unsupported_script` / `docker` hooks) - the tool must operate on files [a pull request]: https://github.com/pre-commit/pre-commit.com/blob/main/sections/hooks.md diff --git a/sections/new-hooks.md b/sections/new-hooks.md index 70699666..7f35b991 100644 --- a/sections/new-hooks.md +++ b/sections/new-hooks.md @@ -155,8 +155,8 @@ Hello from foo hook! - [rust](#rust) - [swift](#swift) - [pygrep](#pygrep) -- [script](#script) -- [system](#system) +- [unsupported](#unsupported) +- [unsupported_script](#unsupported_scripts) ### conda @@ -492,23 +492,27 @@ To require all files to match, use `args: [--negate]`. __Support:__ pygrep hooks are supported on all platforms which pre-commit runs on. -### script +### unsupported -Script hooks provide a way to write simple scripts which validate files. The -[`entry`](#hooks-entry) should be a path relative to the root of the hook repository. +[anchor](__#system) +_new in 4.4.0_: previously `language: system`. the alias will be removed in a +future version + +System hooks provide a way to write hooks for system-level executables which +don't have a supported language above (or have special environment +requirements that don't allow them to run in isolation such as pylint). This hook type will not be given a virtual environment to work with – if it needs additional dependencies the consumer must install them manually. -__Support:__ the support of script hooks depend on the scripts themselves. +### unsupported_script -### system +[anchor](__#script) +_new in 4.4.0_: previously `language: script`. the alias will be removed in a +future version -System hooks provide a way to write hooks for system-level executables which -don't have a supported language above (or have special environment -requirements that don't allow them to run in isolation such as pylint). +Script hooks provide a way to write simple scripts which validate files. The +[`entry`](#hooks-entry) should be a path relative to the root of the hook repository. This hook type will not be given a virtual environment to work with – if it needs additional dependencies the consumer must install them manually. - -__Support:__ the support of system hooks depend on the executables. From de92afe062779e768d861af8ca5ce22734997295 Mon Sep 17 00:00:00 2001 From: Xianpeng Shen Date: Sun, 9 Nov 2025 00:16:32 +0200 Subject: [PATCH 37/68] Update new-hooks.md to fix anchor link --- sections/new-hooks.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sections/new-hooks.md b/sections/new-hooks.md index 7f35b991..6154b821 100644 --- a/sections/new-hooks.md +++ b/sections/new-hooks.md @@ -156,7 +156,7 @@ Hello from foo hook! - [swift](#swift) - [pygrep](#pygrep) - [unsupported](#unsupported) -- [unsupported_script](#unsupported_scripts) +- [unsupported_script](#unsupported_script) ### conda From 287dea84064fa7bb98796eb9d430ca4f005ff090 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 10 Nov 2025 21:00:01 +0000 Subject: [PATCH 38/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/asottile/pyupgrade: v3.21.0 → v3.21.1](https://github.com/asottile/pyupgrade/compare/v3.21.0...v3.21.1) - [github.com/biomejs/pre-commit: v2.3.2 → v2.3.4](https://github.com/biomejs/pre-commit/compare/v2.3.2...v2.3.4) --- .pre-commit-config.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index cc9c126b..f0cb09b8 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -20,7 +20,7 @@ repos: hooks: - id: add-trailing-comma - repo: https://github.com/asottile/pyupgrade - rev: v3.21.0 + rev: v3.21.1 hooks: - id: pyupgrade args: [--py310-plus] @@ -37,7 +37,7 @@ repos: hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit - rev: v2.3.2 + rev: v2.3.4 hooks: - id: biome-check additional_dependencies: ["@biomejs/biome@1.8.1"] From 2aef9432e3a2bcd4eee6f5be4bb2434a53cbf5a2 Mon Sep 17 00:00:00 2001 From: anthony sottile Date: Mon, 17 Nov 2025 13:06:37 -0500 Subject: [PATCH 39/68] update link to oxipng --- sections/hooks.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sections/hooks.md b/sections/hooks.md index 27dc128c..a045f6f6 100644 --- a/sections/hooks.md +++ b/sections/hooks.md @@ -54,11 +54,11 @@ for shell scripts: for the web: - [biomejs/pre-commit]: a fast formatter / fixer written in rust - [standard/standard]: linter / fixer -- [shssoichiro/oxipng]: optimize png files +- [oxipng/oxipng]: optimize png files [biomejs/pre-commit]: https://github.com/biomejs/pre-commit [standard/standard]: https://github.com/standard/standard -[shssoichiro/oxipng]: https://github.com/shssoichiro/oxipng +[oxipng/oxipng]: https://github.com/oxipng/oxipng for configuration files: - [python-jsonschema/check-jsonschema]: check many common configurations with jsonschema From f90e3d7364c92fc9299a52c5916a91e99640994c Mon Sep 17 00:00:00 2001 From: anthony sottile Date: Mon, 17 Nov 2025 13:08:12 -0500 Subject: [PATCH 40/68] remove all-repos.yaml removed references over a year ago in 53aacc6daa654bd0038ad662245286357ac96571 --- all-repos.yaml | 249 ------------------------------------------------- 1 file changed, 249 deletions(-) delete mode 100644 all-repos.yaml diff --git a/all-repos.yaml b/all-repos.yaml deleted file mode 100644 index 90eecf56..00000000 --- a/all-repos.yaml +++ /dev/null @@ -1,249 +0,0 @@ -# This file is used to generate all-hooks.json -- https://github.com/pre-commit/pre-commit-hooks -- https://github.com/pre-commit/mirrors-clang-format -- https://github.com/pre-commit/mirrors-csslint -- https://github.com/pre-commit/mirrors-eslint -- https://github.com/pre-commit/mirrors-fixmyjs -- https://github.com/pre-commit/mirrors-jshint -- https://github.com/pre-commit/mirrors-mypy -- https://github.com/pre-commit/mirrors-puppet-lint -- https://github.com/pre-commit/mirrors-scss-lint -- https://github.com/pre-commit/mirrors-yapf -- https://github.com/pre-commit/pygrep-hooks -- https://github.com/pre-commit/sync-pre-commit-deps -- https://github.com/FalconSocial/pre-commit-mirrors-pep257 -- https://github.com/FalconSocial/pre-commit-python-sorter -- https://github.com/MarketSquare/robotframework-tidy -- https://github.com/guykisel/prospector-mirror -- https://github.com/asottile/add-trailing-comma -- https://github.com/asottile/pyupgrade -- https://github.com/asottile/reorder-python-imports -- https://github.com/asottile/yesqa -- https://github.com/asottile/dead -- https://github.com/asottile/setup-cfg-fmt -- https://github.com/asottile/cheetah_lint -- https://github.com/digitalpulp/pre-commit-php -- https://github.com/elidupuis/mirrors-jscs -- https://github.com/elidupuis/mirrors-sass-lint -# - https://github.com/jumanjihouse/pre-commit-hooks -- https://github.com/jumanjihouse/pre-commit-hook-yamlfmt -- https://github.com/Lucas-C/pre-commit-hooks -# - https://github.com/Lucas-C/pre-commit-hooks-java -- https://github.com/Lucas-C/pre-commit-hooks-lxml -# - https://github.com/Lucas-C/pre-commit-hooks-markup -# - https://github.com/Lucas-C/pre-commit-hooks-nodejs -- https://github.com/Lucas-C/pre-commit-hooks-safety -- https://github.com/chriskuehl/puppet-pre-commit-hooks -- https://github.com/golangci/golangci-lint -- https://github.com/Bahjat/pre-commit-golang -- https://github.com/dnephin/pre-commit-golang -- https://github.com/troian/pre-commit-golang -- https://github.com/jstewmon/check-swagger -- https://github.com/detailyang/pre-commit-shell -- https://github.com/lovesegfault/beautysh -- https://github.com/antonbabenko/pre-commit-terraform -- https://github.com/ansible-community/ansible-lint -- https://github.com/doublify/pre-commit-clang-format -- https://github.com/doublify/pre-commit-go -- https://github.com/doublify/pre-commit-hindent -- https://github.com/doublify/pre-commit-rust -- https://github.com/awebdeveloper/pre-commit-stylelint -- https://github.com/awebdeveloper/pre-commit-tslint -- https://github.com/adrienverge/yamllint -- https://github.com/thlorenz/doctoc -- https://github.com/noahsark769/xcodeproj-sort-pre-commit-hook -- https://github.com/jorisroovers/gitlint -- https://github.com/psf/black -- https://github.com/IamTheFij/ansible-pre-commit -- https://github.com/IamTheFij/docker-pre-commit -- https://github.com/mattlqx/pre-commit-ruby -- https://github.com/mattlqx/pre-commit-sign -- https://github.com/mattlqx/pre-commit-search-and-replace -- https://github.com/pryorda/dockerfilelint-precommit-hooks -- https://github.com/alessandrojcm/commitlint-pre-commit-hook -- https://github.com/henryykt/pre-commit-perl -- https://github.com/juancarlospaco/pre-commit-nim -- https://github.com/aws-cloudformation/cfn-lint -- https://github.com/thoughtworks/talisman -- https://github.com/PyCQA/flake8 -- https://github.com/PyCQA/bandit -- https://github.com/PyCQA/pydocstyle -- https://github.com/PyCQA/pylint -- https://github.com/PyCQA/doc8 -- https://github.com/PyCQA/prospector -- https://github.com/PyCQA/isort -- https://github.com/PyCQA/docformatter -- https://github.com/PyCQA/autoflake -- https://github.com/miki725/importanize -- https://github.com/motet-a/jinjalint -- https://github.com/milin/giticket -- https://github.com/milin/gitown -- https://github.com/sqlalchemyorg/zimports -- https://github.com/peterdemin/pip-compile-multi -- https://github.com/homebysix/pre-commit-macadmin -- https://github.com/fortman/pre-commit-prometheus -- https://github.com/syntaqx/git-hooks -- https://github.com/lunarmodules/luacheck -- https://github.com/Koihik/LuaFormatter -- https://github.com/Calinou/pre-commit-luacheck -- https://github.com/belminf/pre-commit-chef -- https://github.com/pocc/pre-commit-hooks -- https://github.com/dwightgunning/pre-commit-nglint -- https://github.com/codespell-project/codespell -- https://gitlab.com/smop/pre-commit-hooks -- https://github.com/seddonym/import-linter -- https://github.com/marco-c/taskcluster_yml_validator -- https://github.com/rstcheck/rstcheck -- https://github.com/lorenzwalthert/precommit -- https://github.com/lorenzwalthert/gitignore-tidy -- https://github.com/FelixSeptem/pre-commit-golang -- https://gitlab.com/daverona/pre-commit/cpp -- https://github.com/codingjoe/relint -- https://github.com/nix-community/nixpkgs-fmt -- https://github.com/d6e/beancount-check -- https://gitlab.com/iamlikeme/nbhooks -- https://github.com/Vimjas/vint -- https://github.com/eschulte/lisp-format -- https://github.com/shellcheck-py/shellcheck-py -- https://github.com/APIDevTools/swagger-cli -- https://github.com/kynan/nbstripout -- https://gitlab.com/devopshq/gitlab-ci-linter -- https://github.com/bmorcos/pre-commit-hooks-cpp -- https://github.com/igorshubovych/markdownlint-cli -- https://github.com/TekWizely/pre-commit-golang -- https://github.com/markdownlint/markdownlint -- https://github.com/jguttman94/pre-commit-gradle -- https://github.com/Yelp/detect-secrets -- https://github.com/dmitri-lerko/pre-commit-docker-kustomize -- https://github.com/perltidy/perltidy -- https://github.com/talos-systems/conform -- https://github.com/twu/skjold -- https://github.com/commitizen-tools/commitizen -- https://github.com/gherynos/pre-commit-java -- https://github.com/lietu/go-pre-commit -- https://github.com/macisamuele/language-formatters-pre-commit-hooks -- https://github.com/jlebar/pre-commit-hooks -- https://github.com/jazzband/pip-tools -- https://github.com/pappasam/toml-sort -- https://github.com/arenadotio/pre-commit-ocamlformat -- https://github.com/hcodes/yaspeller -- https://github.com/maltzj/google-style-precommit-hook -- https://github.com/jvstein/pre-commit-dotnet-format -- https://github.com/PeterMosmans/jenkinslint -- https://github.com/nicklockwood/SwiftFormat -- https://github.com/executablebooks/mdformat -- https://gitlab.com/daverona/pre-commit/php -- https://github.com/anderseknert/pre-commit-opa -- https://github.com/radix-ai/auto-smart-commit -- https://github.com/thibaudcolas/curlylint -- https://github.com/cheshirekow/cmake-format-precommit -- https://github.com/aorumbayev/pydantic-to-schema -- https://github.com/hadialqattan/pycln -- https://github.com/nbQA-dev/nbQA -- https://github.com/Scony/godot-gdscript-toolkit -- https://github.com/avilaton/add-msg-issue-prefix-hook -- https://github.com/dustinsand/pre-commit-jvm -- https://github.com/alan-turing-institute/CleverCSV-pre-commit -- https://gitlab.com/jvenom/elixir-pre-commit-hooks -- https://github.com/Cretezy/flutter-format-pre-commit -- https://github.com/dluksza/flutter-analyze-pre-commit -- https://github.com/fluttercommunity/import_sorter -- https://github.com/editorconfig-checker/editorconfig-checker.python -- https://gitlab.com/pablodiehl/pre-commit-lua-formatter -- https://github.com/frnmst/md-toc -- https://github.com/mgedmin/check-manifest -# - https://github.com/ecugol/pre-commit-hooks-django -- https://github.com/PrincetonUniversity/blocklint -- https://github.com/python-jsonschema/check-jsonschema -- https://github.com/sirosen/texthooks -- https://github.com/snok/pep585-upgrade -- https://github.com/jendrikseipp/vulture -- https://github.com/mwouts/jupytext -- https://github.com/ejba/pre-commit-maven -- https://github.com/tfsec/tfsec -- https://github.com/yoheimuta/protolint -- https://github.com/hadolint/hadolint -- https://github.com/google/go-jsonnet -- https://github.com/google/yamlfmt -- https://github.com/guid-empty/flutter-dependency-validation-pre-commit -- https://github.com/cpplint/cpplint -- https://github.com/MarcoGorelli/absolufy-imports -- https://github.com/MarcoGorelli/auto-walrus -- https://github.com/MarcoGorelli/cython-lint -- https://github.com/domdfcoding/flake2lint -- https://github.com/dotnet/format -- https://github.com/ashwin153/pre-commit-vagrant -- https://github.com/AleksaC/hadolint-py -- https://github.com/AleksaC/circleci-cli-py -- https://github.com/AleksaC/mirrors-cfn-nag -- https://github.com/cmake-lint/cmake-lint -- https://github.com/priv-kweihmann/oelint-adv -- https://github.com/jggomez/pre-commit-android-kotlin -- https://github.com/Carreau/velin -- https://github.com/chrismgrayftsinc/jsonnetfmt -- https://github.com/zricethezav/gitleaks -- https://github.com/hugoh/pre-commit-fish -# - https://github.com/nbyl/pre-commit-license-checks -# - https://github.com/jonasbb/pre-commit-latex-hooks -- https://github.com/dfm/black_nbconvert -- https://github.com/crate-ci/typos -- https://github.com/snakemake/snakefmt -- https://github.com/regebro/pyroma -- https://github.com/tox-dev/tox-ini-fmt -- https://github.com/janosh/format-ipy-cells -- https://github.com/FalcoSuessgott/lint-gitlab-ci -- https://github.com/comkieffer/xml-linter-hook -- https://github.com/jackdewinter/pymarkdown -- https://github.com/klieret/jekyll-relative-url-check -- https://github.com/tarioch/flux-check-hook -- https://github.com/streetsidesoftware/cspell-cli -- https://github.com/rapidsai/frigate -- https://github.com/norwoodj/helm-docs -- https://github.com/sqlfluff/sqlfluff -- https://github.com/adamchainz/blacken-docs -- https://github.com/adamchainz/django-upgrade -- https://github.com/scop/pre-commit-shfmt -- https://github.com/scop/pre-commit-perlcritic -- https://github.com/BlankSpruce/gersemi -- https://github.com/realm/SwiftLint -- https://gitlab.com/bmares/check-json5 -- https://github.com/semaphor-dk/dansabel -- https://github.com/gitguardian/gg-shield -- https://github.com/JohnnyMorganz/StyLua -- https://github.com/shssoichiro/oxipng -- https://github.com/datarootsio/databooks -- https://github.com/standard/standard -- https://github.com/Sceptre/sceptrelint -- https://github.com/lyz-code/yamlfix -- https://github.com/dannysepler/rm_unneeded_f_str -- https://github.com/cmhughes/latexindent.pl -- https://github.com/sirwart/ripsecrets -- https://github.com/bagerard/graphviz-dot-hooks -- https://github.com/omnilib/ufmt -- https://github.com/daveshanley/vacuum -- https://github.com/nuztalgia/botstrap -- https://gitlab.com/adam-moss/pre-commit-trailer -- https://gitlab.com/adam-moss/pre-commit-ssh-git-signing-key -- https://github.com/astral-sh/ruff-pre-commit -- https://github.com/mrtazz/checkmake -- https://github.com/jshwi/docsig -- https://github.com/finsberg/clang-format-docs -- https://github.com/rubocop/rubocop -- https://github.com/dbt-checkpoint/dbt-checkpoint -- https://gitlab.com/engmark/vcard -- https://github.com/Data-Liberation-Front/csvlint.rb -- https://github.com/christopher-hacker/enforce-notebook-run-order -- https://github.com/mxr/unkey -- https://github.com/Mateusz-Grzelinski/actionlint-py -- https://github.com/andrewring/github-distributed-owners -- https://github.com/Mermeid-Designs/pydantic-hooks -- https://github.com/igrr/astyle_py -- https://gitlab.com/codementors/pre-commit/add-issue-number-to-conventional-commit -- https://github.com/numpy/numpydoc -- https://github.com/hakancelikdev/unimport -- https://github.com/hakancelikdev/unexport -- https://github.com/KindDragon/gn-build-py -- https://github.com/stefmolin/exif-stripper -- https://github.com/hhatto/autopep8 -- https://github.com/rhysd/actionlint -- https://github.com/hija/clean-dotenv From f8f9c9315572bb7e40b18c26bd7bf44295d09f25 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 17 Nov 2025 20:30:37 +0000 Subject: [PATCH 41/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/biomejs/pre-commit: v2.3.4 → v2.3.5](https://github.com/biomejs/pre-commit/compare/v2.3.4...v2.3.5) --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index f0cb09b8..07211466 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -37,7 +37,7 @@ repos: hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit - rev: v2.3.4 + rev: v2.3.5 hooks: - id: biome-check additional_dependencies: ["@biomejs/biome@1.8.1"] From f35f043f5e64adf8f8e5c996f4c0508b13d85f86 Mon Sep 17 00:00:00 2001 From: anthony sottile Date: Sat, 22 Nov 2025 16:48:14 -0500 Subject: [PATCH 42/68] document `pre-commit hazmat` --- sections/advanced.md | 93 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 93 insertions(+) diff --git a/sections/advanced.md b/sections/advanced.md index b5f7f227..442dbff1 100644 --- a/sections/advanced.md +++ b/sections/advanced.md @@ -352,6 +352,99 @@ The currently available `meta` hooks: debugging. ``` +## `pre-commit hazmat` + +"hazardous materials" + +pre-commit provides a few `entry` prefix "helpers" for unusual situations. + +in case it's not clear, using these is _usually_ a bad idea. + +_note_: hazmat helpers do not work on languages which adjust `entry` (`docker` +/ `docker_image` / `fail` / `julia` / `pygrep` / `r` / `unsupported_script`). + +### `pre-commit hazmat cd` + +_new in 4.5.0_ + +for "monorepo" usage one can use this to target a subdirectory. + +this entry prefix will cd to the target subdir and adjust filename arguments + +example usage: + +```yaml +# recommended: +# minimum_pre_commit_version: 4.5.0 +repos: +- repo: ... + rev: ... + hooks: + - id: example + alias: example-repo1 + name: example (repo1) + files: ^repo1/ + # important! ends with `--` + # important! copy `args: [...]` to entry and blank out `args: []` + entry: pre-commit hazmat cd repo1 example-bin --arg1 -- + args: [] + + - id: example + alias: example-repo2 + name: example (repo2) + files: ^repo2/ + entry: pre-commit hazmat cd repo2 example-bin --arg1 -- + args: [] + + # ... etc. +``` + +### `pre-commit hazmat ignore-exit-code` + +_new in 4.5.0_ + +it's a bad idea to introduce warning noise but this gives you a way to do it. + +example: + +```yaml +# recommended: +# minimum_pre_commit_version: 4.5.0 +repos: +- repo: ... + rev: ... + hooks: + - id: example + # important! copy `args: [...]` to entry and blank out `args: []` + entry: pre-commit hazmat ignore-exit-code example-bin --arg1 -- + args: [] + # otherwise the output will always be hidden + verbose: true +``` + +### `pre-commit hazmat n1` + +_new in 4.5.0_ + +some hooks only take one filename argument. this runs them one at a time +(which is super slow!) + +example: + +```yaml +# recommended: +# minimum_pre_commit_version: 4.5.0 +repos: +- repo: ... + rev: ... + hooks: + - id: example + # important! ends with `--` + # important! copy `args: [...]` to entry and blank out `args: []` + entry: pre-commit hazmat n1 example-bin --arg1 -- + args: [] +``` + ## automatically enabling pre-commit on repositories `pre-commit init-templatedir` can be used to set up a skeleton for `git`'s From d09459c1fbdd6fd7b8509f0a501cd63c8c9ed356 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 24 Nov 2025 20:53:51 +0000 Subject: [PATCH 43/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/asottile/pyupgrade: v3.21.1 → v3.21.2](https://github.com/asottile/pyupgrade/compare/v3.21.1...v3.21.2) - [github.com/biomejs/pre-commit: v2.3.5 → v2.3.7](https://github.com/biomejs/pre-commit/compare/v2.3.5...v2.3.7) --- .pre-commit-config.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 07211466..a6474e83 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -20,7 +20,7 @@ repos: hooks: - id: add-trailing-comma - repo: https://github.com/asottile/pyupgrade - rev: v3.21.1 + rev: v3.21.2 hooks: - id: pyupgrade args: [--py310-plus] @@ -37,7 +37,7 @@ repos: hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit - rev: v2.3.5 + rev: v2.3.7 hooks: - id: biome-check additional_dependencies: ["@biomejs/biome@1.8.1"] From 6740110ea1c43d84c6cea09d45ab87d7137ff48c Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 1 Dec 2025 21:05:21 +0000 Subject: [PATCH 44/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/pre-commit/mirrors-mypy: v1.18.2 → v1.19.0](https://github.com/pre-commit/mirrors-mypy/compare/v1.18.2...v1.19.0) - [github.com/biomejs/pre-commit: v2.3.7 → v2.3.8](https://github.com/biomejs/pre-commit/compare/v2.3.7...v2.3.8) --- .pre-commit-config.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index a6474e83..113669b1 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -33,11 +33,11 @@ repos: hooks: - id: flake8 - repo: https://github.com/pre-commit/mirrors-mypy - rev: v1.18.2 + rev: v1.19.0 hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit - rev: v2.3.7 + rev: v2.3.8 hooks: - id: biome-check additional_dependencies: ["@biomejs/biome@1.8.1"] From 92414a56f02690b8a895332b5c7bde18087b7967 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 15 Dec 2025 20:49:03 +0000 Subject: [PATCH 45/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/pre-commit/mirrors-mypy: v1.19.0 → v1.19.1](https://github.com/pre-commit/mirrors-mypy/compare/v1.19.0...v1.19.1) --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 113669b1..088e0d95 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -33,7 +33,7 @@ repos: hooks: - id: flake8 - repo: https://github.com/pre-commit/mirrors-mypy - rev: v1.19.0 + rev: v1.19.1 hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit From 47556e078482b9500d75acb2670e8cee87b49ea2 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 22 Dec 2025 20:26:31 +0000 Subject: [PATCH 46/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/biomejs/pre-commit: v2.3.8 → v2.3.10](https://github.com/biomejs/pre-commit/compare/v2.3.8...v2.3.10) --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 088e0d95..84487e17 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -37,7 +37,7 @@ repos: hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit - rev: v2.3.8 + rev: v2.3.10 hooks: - id: biome-check additional_dependencies: ["@biomejs/biome@1.8.1"] From 392108ef916d5c87836a842f41f4c31b364d2448 Mon Sep 17 00:00:00 2001 From: abhro <5664668+abhro@users.noreply.github.com> Date: Sat, 3 Jan 2026 08:00:42 -0500 Subject: [PATCH 47/68] Add julia to supported languages in new-hooks.md --- sections/new-hooks.md | 1 + 1 file changed, 1 insertion(+) diff --git a/sections/new-hooks.md b/sections/new-hooks.md index 6154b821..587ccfd5 100644 --- a/sections/new-hooks.md +++ b/sections/new-hooks.md @@ -146,6 +146,7 @@ Hello from foo hook! - [fail](#fail) - [golang](#golang) - [haskell](#haskell) +- [julia](#julia) - [lua](#lua) - [node](#node) - [perl](#perl) From b587ec453054ee5c8949019783f9a7c21dcd4a7a Mon Sep 17 00:00:00 2001 From: Anthony Sottile Date: Fri, 30 Jan 2026 14:44:41 -0500 Subject: [PATCH 48/68] document validate-config / validate-manifest --- sections/cli.md | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/sections/cli.md b/sections/cli.md index a644a0ae..56b74d76 100644 --- a/sections/cli.md +++ b/sections/cli.md @@ -233,3 +233,11 @@ Uninstall the pre-commit script. Options: - `-t HOOK_TYPE, --hook-type HOOK_TYPE`: which hook type to uninstall. + +## pre-commit validate-config [options] [filenames ...] #pre-commit-validate-config + +Validate .pre-commit-config.yaml files + +## pre-commit validate-manifest [options] [filenames ...] #pre-commit-validate-manifest + +Validate .pre-commit-hooks.yaml files From a4aafb147834fe1af11d6b4764f7c9ed98440974 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 9 Feb 2026 21:49:04 +0000 Subject: [PATCH 49/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/biomejs/pre-commit: v2.3.10 → v2.3.14](https://github.com/biomejs/pre-commit/compare/v2.3.10...v2.3.14) --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 84487e17..387a3ac4 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -37,7 +37,7 @@ repos: hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit - rev: v2.3.10 + rev: v2.3.14 hooks: - id: biome-check additional_dependencies: ["@biomejs/biome@1.8.1"] From 106554d73c04a35d8517a9d67efeb955c225e66a Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 16 Feb 2026 20:28:58 +0000 Subject: [PATCH 50/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/biomejs/pre-commit: v2.3.14 → v2.3.15](https://github.com/biomejs/pre-commit/compare/v2.3.14...v2.3.15) --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 387a3ac4..fb5e9799 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -37,7 +37,7 @@ repos: hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit - rev: v2.3.14 + rev: v2.3.15 hooks: - id: biome-check additional_dependencies: ["@biomejs/biome@1.8.1"] From 931459f771fdc6e5e7a1606fc07cbce5d195d2d6 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 23 Feb 2026 20:56:37 +0000 Subject: [PATCH 51/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/biomejs/pre-commit: v2.3.15 → v2.4.4](https://github.com/biomejs/pre-commit/compare/v2.3.15...v2.4.4) --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index fb5e9799..3069f855 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -37,7 +37,7 @@ repos: hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit - rev: v2.3.15 + rev: v2.4.4 hooks: - id: biome-check additional_dependencies: ["@biomejs/biome@1.8.1"] From ccd7e31d699538dcaec7078594412588457ef572 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 9 Mar 2026 21:09:12 +0000 Subject: [PATCH 52/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/biomejs/pre-commit: v2.4.4 → v2.4.6](https://github.com/biomejs/pre-commit/compare/v2.4.4...v2.4.6) --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 3069f855..1c32b889 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -37,7 +37,7 @@ repos: hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit - rev: v2.4.4 + rev: v2.4.6 hooks: - id: biome-check additional_dependencies: ["@biomejs/biome@1.8.1"] From d1294c3ef7d41512cd89088eaa7d8c7b8951ac21 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 16 Mar 2026 21:03:18 +0000 Subject: [PATCH 53/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/biomejs/pre-commit: v2.4.6 → v2.4.7](https://github.com/biomejs/pre-commit/compare/v2.4.6...v2.4.7) --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 1c32b889..93069c8c 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -37,7 +37,7 @@ repos: hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit - rev: v2.4.6 + rev: v2.4.7 hooks: - id: biome-check additional_dependencies: ["@biomejs/biome@1.8.1"] From a284af67b082a1f8d60fba10506a980e6ea3914d Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 23 Mar 2026 20:36:28 +0000 Subject: [PATCH 54/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/biomejs/pre-commit: v2.4.7 → v2.4.8](https://github.com/biomejs/pre-commit/compare/v2.4.7...v2.4.8) --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 93069c8c..a9c89401 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -37,7 +37,7 @@ repos: hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit - rev: v2.4.7 + rev: v2.4.8 hooks: - id: biome-check additional_dependencies: ["@biomejs/biome@1.8.1"] From ce931e1cd46262fd5099ba95b7325e7adbc732ff Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 30 Mar 2026 20:36:34 +0000 Subject: [PATCH 55/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/biomejs/pre-commit: v2.4.8 → v2.4.9](https://github.com/biomejs/pre-commit/compare/v2.4.8...v2.4.9) --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index a9c89401..d9af6322 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -37,7 +37,7 @@ repos: hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit - rev: v2.4.8 + rev: v2.4.9 hooks: - id: biome-check additional_dependencies: ["@biomejs/biome@1.8.1"] From ef83ef1d8cda38ab346e3674c4f6b824139067c7 Mon Sep 17 00:00:00 2001 From: Matthew Hughes Date: Thu, 26 Mar 2026 20:48:48 +0000 Subject: [PATCH 56/68] Document `PRE_COMMIT` environment variable Document this variable, exposed since `v2.5.0`[1], as a way to determine if `pre-commit` is running. Because It took a bit of searching in the `pre-commit` repo to discover the existence of this variable. Link: https://github.com/pre-commit/pre-commit/commit/2f25085d60bf953fea457a3240c91886145dbcc5 [1] --- sections/new-hooks.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/sections/new-hooks.md b/sections/new-hooks.md index 587ccfd5..7f21d439 100644 --- a/sections/new-hooks.md +++ b/sections/new-hooks.md @@ -4,6 +4,9 @@ installable package (gem, npm, pypi, etc.) or exposes an executable, it can be used with pre-commit. Each git repo can support as many languages/hooks as you want. +_new in 2.5.0_: `pre-commit` sets the `PRE_COMMIT=1` environment variable +during hook execution. + The hook must exit nonzero on failure or modify files. A git repo containing pre-commit plugins must contain a `.pre-commit-hooks.yaml` From 6a6a0a195871b9fd8368086d3094ea62814d5b82 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 6 Apr 2026 21:10:15 +0000 Subject: [PATCH 57/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/pre-commit/mirrors-mypy: v1.19.1 → v1.20.0](https://github.com/pre-commit/mirrors-mypy/compare/v1.19.1...v1.20.0) - [github.com/biomejs/pre-commit: v2.4.9 → v2.4.10](https://github.com/biomejs/pre-commit/compare/v2.4.9...v2.4.10) --- .pre-commit-config.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index d9af6322..c94d0e68 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -33,11 +33,11 @@ repos: hooks: - id: flake8 - repo: https://github.com/pre-commit/mirrors-mypy - rev: v1.19.1 + rev: v1.20.0 hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit - rev: v2.4.9 + rev: v2.4.10 hooks: - id: biome-check additional_dependencies: ["@biomejs/biome@1.8.1"] From d82a43cfe3aa29a4d8644d059931086acd9fbd69 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 13 Apr 2026 20:41:26 +0000 Subject: [PATCH 58/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/pre-commit/mirrors-mypy: v1.20.0 → v1.20.1](https://github.com/pre-commit/mirrors-mypy/compare/v1.20.0...v1.20.1) - [github.com/biomejs/pre-commit: v2.4.10 → v2.4.11](https://github.com/biomejs/pre-commit/compare/v2.4.10...v2.4.11) --- .pre-commit-config.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index c94d0e68..715ec127 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -33,11 +33,11 @@ repos: hooks: - id: flake8 - repo: https://github.com/pre-commit/mirrors-mypy - rev: v1.20.0 + rev: v1.20.1 hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit - rev: v2.4.10 + rev: v2.4.11 hooks: - id: biome-check additional_dependencies: ["@biomejs/biome@1.8.1"] From 301d2b619a8d446a0164a097a16c2f6370ea949b Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 20 Apr 2026 20:26:11 +0000 Subject: [PATCH 59/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/biomejs/pre-commit: v2.4.11 → v2.4.12](https://github.com/biomejs/pre-commit/compare/v2.4.11...v2.4.12) --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 715ec127..110c92ec 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -37,7 +37,7 @@ repos: hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit - rev: v2.4.11 + rev: v2.4.12 hooks: - id: biome-check additional_dependencies: ["@biomejs/biome@1.8.1"] From 756f7abd18d28c207e5c6f6d276c8ef87efc0d70 Mon Sep 17 00:00:00 2001 From: anthony sottile Date: Tue, 21 Apr 2026 17:11:08 -0400 Subject: [PATCH 60/68] document support for git 2.54+ hooks --- sections/advanced.md | 71 ++++++++++++++++++++++++++++++++++++++++++++ template_lib.py | 2 +- 2 files changed, 72 insertions(+), 1 deletion(-) diff --git a/sections/advanced.md b/sections/advanced.md index 442dbff1..e7531157 100644 --- a/sections/advanced.md +++ b/sections/advanced.md @@ -445,8 +445,79 @@ repos: args: [] ``` +## usage with git 2.54+ hook configuration + +_new in 4.6.0_: pre-commit improved support for `git config`-based hooks. +a later version will change `pre-commit install` to use this approach. + +[git 2.54] introduced a new way to install git hook tools via `git config`. + +the basic gist is the following enables a hook in a git repo: + +```bash +git config set hook..event pre-push +git config set hook..command 'some command here' +``` + +an example setup with `pre-commit` might look like: + +```bash +# note, the "hook" name here is `pre-commit.pre-commit` +# for the `pre-commit` "tool" and the `pre-commit` "event" +git config set hook.pre-commit.pre-commit.event pre-commit +git config set hook.pre-commit.pre-commit.command 'pre-commit hook-impl --hook-type pre-commit --' + +# please follow that naming scheme for future compatibility with `pre-commit install` + +# an example with pre-push: +# +# git config set hook.pre-commit.pre-push.event pre-push +# git config set hook.pre-commit.pre-push.command 'pre-commit hook-impl --hook-type pre-push --' +``` + +`pre-commit hook-impl` is a "hidden" implementation command with these options: +- `--hook-type ...`: the [hook type](#supported-git-hooks) to use +- `--skip-on-missing-config`: silently pass when a config is missing + +some interesting applications of this: + +### "global" installation of pre-commit + +with `git config set --global ...` this can automatically enable pre-commit +for all repositories: + +```bash +git config set --global hook.pre-commit.pre-commit.event pre-commit +git config set --global hook.pre-commit.pre-commit.command 'pre-commit hook-impl --hook-type pre-commit --skip-on-missing-config --' +``` + +- this setup **not recommended** as it can lead to accidentally running hooks + when interacting with an untrusted repository. +- `--skip-on-missing-config` is recommended here as arbitrary git repositories + may not have a `.pre-commit-config.yaml`. + +### always running a hook on all files + +since you can configure pre-commit as many times as you want you *could* invoke +pre-commit to run a particular hook always and on all files + +```bash +git config set hook.pre-commit.pre-commit-always.event pre-commit +git config set hook.pre-commit.pre-commit-always.command 'pre-commit run hookid --hook-stage pre-commit --all-files' +``` + +*note*: this is not recommended as it has the tendancy to be slow and deviates +from the normal expectations of pre-commit. + +[git 2.54]: https://github.blog/open-source/git/highlights-from-git-2-54/#h-config-based-hooks + ## automatically enabling pre-commit on repositories +*note*: if you are on a new-enough version of `git` you may want to use +[this approach](#global-installation-of-pre-commit) instead. + +___ + `pre-commit init-templatedir` can be used to set up a skeleton for `git`'s `init.templateDir` option. This means that any newly cloned repository will automatically have the hooks set up without the need to run diff --git a/template_lib.py b/template_lib.py index 05a26c61..72286d70 100644 --- a/template_lib.py +++ b/template_lib.py @@ -12,7 +12,7 @@ ID_RE = re.compile(r' #([a-z0-9-]+)$') -SPECIAL_CHARS_RE = re.compile('[^a-z0-9 _-]') +SPECIAL_CHARS_RE = re.compile('(&[a-z]+;|[^a-z0-9 _-])') ROW = '=r=' From 54cd70dfa20378d2c656f1b764e02966587629ad Mon Sep 17 00:00:00 2001 From: anthony sottile Date: Wed, 22 Apr 2026 09:32:44 -0400 Subject: [PATCH 61/68] also document --config for hook-impl --- sections/advanced.md | 1 + 1 file changed, 1 insertion(+) diff --git a/sections/advanced.md b/sections/advanced.md index e7531157..646f2ac1 100644 --- a/sections/advanced.md +++ b/sections/advanced.md @@ -477,6 +477,7 @@ git config set hook.pre-commit.pre-commit.command 'pre-commit hook-impl --hook-t `pre-commit hook-impl` is a "hidden" implementation command with these options: - `--hook-type ...`: the [hook type](#supported-git-hooks) to use +- `--config ...`: (optional) path to `.pre-commit-config.yaml` - `--skip-on-missing-config`: silently pass when a config is missing some interesting applications of this: From dfcca29ccab42fe6f0561b12932d4b8ace60cf32 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 27 Apr 2026 21:08:43 +0000 Subject: [PATCH 62/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/pre-commit/mirrors-mypy: v1.20.1 → v1.20.2](https://github.com/pre-commit/mirrors-mypy/compare/v1.20.1...v1.20.2) - [github.com/biomejs/pre-commit: v2.4.12 → v2.4.13](https://github.com/biomejs/pre-commit/compare/v2.4.12...v2.4.13) --- .pre-commit-config.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 110c92ec..30c8fc25 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -33,11 +33,11 @@ repos: hooks: - id: flake8 - repo: https://github.com/pre-commit/mirrors-mypy - rev: v1.20.1 + rev: v1.20.2 hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit - rev: v2.4.12 + rev: v2.4.13 hooks: - id: biome-check additional_dependencies: ["@biomejs/biome@1.8.1"] From 680799de09a2f9415eb5d22cb8f6f0a6d5f903ba Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 4 May 2026 20:31:48 +0000 Subject: [PATCH 63/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/biomejs/pre-commit: v2.4.13 → v2.4.14](https://github.com/biomejs/pre-commit/compare/v2.4.13...v2.4.14) --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 30c8fc25..2d92b1f3 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -37,7 +37,7 @@ repos: hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit - rev: v2.4.13 + rev: v2.4.14 hooks: - id: biome-check additional_dependencies: ["@biomejs/biome@1.8.1"] From f0b1c6a2207ad6f5d79351fc4f8e275755392b23 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 11 May 2026 20:24:43 +0000 Subject: [PATCH 64/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/pre-commit/mirrors-mypy: v1.20.2 → v2.0.0](https://github.com/pre-commit/mirrors-mypy/compare/v1.20.2...v2.0.0) - [github.com/biomejs/pre-commit: v2.4.14 → v2.4.15](https://github.com/biomejs/pre-commit/compare/v2.4.14...v2.4.15) --- .pre-commit-config.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 2d92b1f3..f387ba22 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -33,11 +33,11 @@ repos: hooks: - id: flake8 - repo: https://github.com/pre-commit/mirrors-mypy - rev: v1.20.2 + rev: v2.0.0 hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit - rev: v2.4.14 + rev: v2.4.15 hooks: - id: biome-check additional_dependencies: ["@biomejs/biome@1.8.1"] From b73acadb5076665198f4adba5fe5a6dff73a5876 Mon Sep 17 00:00:00 2001 From: Max R Date: Mon, 18 May 2026 14:49:29 -0400 Subject: [PATCH 65/68] Remove redundant Biome pre-commit additional dependencies and update biome.json Committed via https://github.com/asottile/all-repos --- .pre-commit-config.yaml | 1 - biome.json | 10 +++++++--- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index f387ba22..29d3782a 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -40,4 +40,3 @@ repos: rev: v2.4.15 hooks: - id: biome-check - additional_dependencies: ["@biomejs/biome@1.8.1"] diff --git a/biome.json b/biome.json index 03e2df98..e99b718f 100644 --- a/biome.json +++ b/biome.json @@ -1,7 +1,11 @@ { - "$schema": "https://biomejs.dev/schemas/1.4.0/schema.json", - "organizeImports": { - "enabled": false + "$schema": "https://biomejs.dev/schemas/2.4.15/schema.json", + "assist": { + "actions": { + "source": { + "organizeImports": "off" + } + } }, "formatter": { "indentStyle": "space", From 6b4b9a1f7420768662d652507f72af727178c22a Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 18 May 2026 21:13:41 +0000 Subject: [PATCH 66/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/pre-commit/mirrors-mypy: v2.0.0 → v2.1.0](https://github.com/pre-commit/mirrors-mypy/compare/v2.0.0...v2.1.0) --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 29d3782a..79c2fe2f 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -33,7 +33,7 @@ repos: hooks: - id: flake8 - repo: https://github.com/pre-commit/mirrors-mypy - rev: v2.0.0 + rev: v2.1.0 hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit From 6af0665b1e586d58be0daeea8e2aaaf5b6510cd9 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 1 Jun 2026 21:27:25 +0000 Subject: [PATCH 67/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/biomejs/pre-commit: v2.4.15 → v2.4.16](https://github.com/biomejs/pre-commit/compare/v2.4.15...v2.4.16) --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 79c2fe2f..885239ae 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -37,6 +37,6 @@ repos: hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit - rev: v2.4.15 + rev: v2.4.16 hooks: - id: biome-check From c4ac9996467da7979c67c4deab15631a530d5e67 Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 15 Jun 2026 20:47:05 +0000 Subject: [PATCH 68/68] [pre-commit.ci] pre-commit autoupdate MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit updates: - [github.com/biomejs/pre-commit: v2.4.16 → v2.5.0](https://github.com/biomejs/pre-commit/compare/v2.4.16...v2.5.0) --- .pre-commit-config.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 885239ae..1f2f8c10 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -37,6 +37,6 @@ repos: hooks: - id: mypy - repo: https://github.com/biomejs/pre-commit - rev: v2.4.16 + rev: v2.5.0 hooks: - id: biome-check