AReaL/.pre-commit-config.yaml

61 lines
1.5 KiB
YAML

repos:
- repo: https://github.com/pre-commit/mirrors-clang-format
rev: v19.1.7
hooks:
- id: clang-format
files: \.(c|cc|cxx|cpp|h|hpp|hxx|cu|cuh)$
args:
- --style=file
- --fallback-style=Google
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.4.0
hooks:
- id: check-yaml
files: \.(yaml|yml)$
- id: end-of-file-fixer
files: \.(py|md|yaml|yml|c|cc|cxx|cpp|h|hpp|hxx|cu|cuh)$
- id: trailing-whitespace
files: \.(py|md|yaml|yml|c|cc|cxx|cpp|h|hpp|hxx|cu|cuh)$
- repo: https://github.com/executablebooks/mdformat
rev: 0.7.17
hooks:
- id: mdformat
args:
- --wrap=88
additional_dependencies:
- mdformat-gfm
- mdformat-tables
- mdformat-frontmatter
- repo: https://github.com/pycqa/autoflake
rev: v2.3.1
hooks:
- id: autoflake
args:
- -i
- -r
- --remove-all-unused-imports
- --remove-unused-variables
files: ^(arealite/|examples/arealite/).*\.py$
- repo: https://github.com/pycqa/isort
rev: 5.13.2
hooks:
- id: isort
args:
- --profile=black
- --multi-line=3
- --line-length=88
files: \.py$
- repo: https://github.com/psf/black/
rev: 25.1.0
hooks:
- id: black
language_version: python3
args:
- --line-length=88
files: \.py$