mirror of
https://github.com/home-assistant/core.git
synced 2025-07-29 18:28:14 +02:00
Update ruff to 0.11.12 (#146037)
* Update ruff to 0.11.12 * Replace ruff legacy alias with ruff-check
This commit is contained in:
@ -249,6 +249,10 @@ GENERATED_MESSAGE = (
|
||||
f"# Automatically generated by {Path(__file__).name}, do not edit\n\n"
|
||||
)
|
||||
|
||||
MAP_HOOK_ID_TO_PACKAGE = {
|
||||
"ruff-check": "ruff",
|
||||
}
|
||||
|
||||
IGNORE_PRE_COMMIT_HOOK_ID = (
|
||||
"check-executables-have-shebangs",
|
||||
"check-json",
|
||||
@ -523,7 +527,8 @@ def requirements_pre_commit_output() -> str:
|
||||
rev: str = repo["rev"]
|
||||
for hook in repo["hooks"]:
|
||||
if hook["id"] not in IGNORE_PRE_COMMIT_HOOK_ID:
|
||||
reqs.append(f"{hook['id']}=={rev.lstrip('v')}")
|
||||
pkg = MAP_HOOK_ID_TO_PACKAGE.get(hook["id"]) or hook["id"]
|
||||
reqs.append(f"{pkg}=={rev.lstrip('v')}")
|
||||
reqs.extend(x for x in hook.get("additional_dependencies", ()))
|
||||
output = [
|
||||
f"# Automatically generated "
|
||||
|
Reference in New Issue
Block a user