mirror of
https://github.com/github/codeql.git
synced 2025-12-16 16:53:25 +01:00
Add black pre-commit hook
This switched `codegen` from the `autopep8` formatting to the `black` one, and applies it to `bulk_mad_generator.py` as well. We can enroll more python scripts to it in the future.
This commit is contained in:
@@ -14,11 +14,11 @@ repos:
|
||||
hooks:
|
||||
- id: clang-format
|
||||
|
||||
- repo: https://github.com/pre-commit/mirrors-autopep8
|
||||
rev: v2.0.4
|
||||
- repo: https://github.com/psf/black
|
||||
rev: 25.1.0
|
||||
hooks:
|
||||
- id: autopep8
|
||||
files: ^misc/codegen/.*\.py
|
||||
- id: black
|
||||
files: ^(misc/codegen/.*|misc/scripts/models-as-data/bulk_generate_mad)\.py$
|
||||
|
||||
- repo: local
|
||||
hooks:
|
||||
|
||||
Reference in New Issue
Block a user