@@ -28,7 +28,7 @@ class PreCommit:
2828 url = mk_url ("style" )
2929 renamed : ClassVar [dict [str , str ]] = {}
3030 repos : ClassVar [set [str ]] = set ()
31- ids : ClassVar [dict [str , str ]] = {}
31+ ids : ClassVar [dict [str , set [ str ] ]] = {}
3232
3333 @property
3434 def describe (self ) -> str :
@@ -53,7 +53,7 @@ def check(cls, precommit: dict[str, Any]) -> bool | None | str:
5353 if repo in cls .repos :
5454 if cls .ids and repo in cls .ids :
5555 if any (
56- hook .get ("id" , "" ) == cls .ids [repo ]
56+ hook .get ("id" , "" ) in cls .ids [repo ]
5757 for hook in repo_item .get ("hooks" , {})
5858 ):
5959 return True
@@ -83,7 +83,7 @@ class PC110(PreCommit):
8383 renamed = {
8484 "https://github.com/psf/black" : "https://github.com/psf/black-pre-commit-mirror"
8585 }
86- ids = {"https://github.com/astral-sh/ruff-pre-commit" : "ruff-format" }
86+ ids = {"https://github.com/astral-sh/ruff-pre-commit" : { "ruff-format" } }
8787
8888
8989class PC111 (PreCommit ):
@@ -97,12 +97,17 @@ class PC111(PreCommit):
9797
9898
9999class PC190 (PreCommit ):
100- "Uses Ruff"
100+ "Uses a linter ( Ruff/Flake8) "
101101
102- repos = {"https://github.com/astral-sh/ruff-pre-commit" }
102+ repos = {
103+ "https://github.com/astral-sh/ruff-pre-commit" ,
104+ "https://github.com/pycqa/flake8" ,
105+ }
103106 renamed = {
104- "https://github.com/charliermarsh/ruff-pre-commit" : "https://github.com/astral-sh/ruff-pre-commit"
107+ "https://github.com/charliermarsh/ruff-pre-commit" : "https://github.com/astral-sh/ruff-pre-commit" ,
108+ "https://gitlab.com/pycqa/flake8 " : "https://github.com/pycqa/flake8" ,
105109 }
110+ ids = {"https://github.com/astral-sh/ruff-pre-commit" : {"ruff-check" , "ruff" }}
106111
107112
108113class PC140 (PreCommit ):
0 commit comments