-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.pre-commit-config.yaml
31 lines (31 loc) · 1.57 KB
/
.pre-commit-config.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
# Apply to all files without commiting:
# pre-commit run --all-files
# Update this file:
# pre-commit autoupdate
exclude: "docs"
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.4.0
hooks:
- id: check-ast # Simply check whether files parse as valid python.
- id: fix-byte-order-marker # removes UTF-8 byte order marker
- id: check-case-conflict # Check for files with names that would conflict on a case-insensitive filesystem
- id: check-executables-have-shebangs # Checks that non-binary executables have a proper shebang.
- id: check-shebang-scripts-are-executable # ensures that (non-binary) files with a shebang are executable.
- id: check-xml # Attempts to load all xml files to verify syntax.
- id: check-json # Attempts to load all json files to verify syntax.
- id: check-yaml # Attempts to load all yaml files to verify syntax.
- id: detect-private-key # Checks for the existence of private keys.
- id: end-of-file-fixer # Makes sure files end in a newline and only a newline.
- id: double-quote-string-fixer # Replaces double quoted strings with single quoted strings.
- id: trailing-whitespace # Trims trailing whitespace.
- id: mixed-line-ending # Replaces or checks mixed line ending.
- repo: https://github.com/pre-commit/mirrors-autopep8
rev: "v2.0.2"
hooks:
- id: autopep8 # Automatic pep8 style formatting for python files
- repo: https://github.com/pre-commit/mirrors-clang-format
rev: v10.0.1
hooks:
- id: clang-format
types_or: [c++, c]