add pre-commit
Browse files- .pre-commit-config.yaml +36 -0
.pre-commit-config.yaml
ADDED
|
@@ -0,0 +1,36 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
default_install_hook_types:
|
| 2 |
+
- pre-commit
|
| 3 |
+
- commit-msg
|
| 4 |
+
default_stages:
|
| 5 |
+
- pre-commit # Run locally
|
| 6 |
+
- manual # Run in CI
|
| 7 |
+
exclude: '(build|result)/.*'
|
| 8 |
+
repos:
|
| 9 |
+
- repo: https://github.com/google/yapf
|
| 10 |
+
rev: v0.43.0
|
| 11 |
+
hooks:
|
| 12 |
+
- id: yapf
|
| 13 |
+
args: [--in-place, --verbose]
|
| 14 |
+
- repo: https://github.com/crate-ci/typos
|
| 15 |
+
rev: v1.34.0
|
| 16 |
+
hooks:
|
| 17 |
+
- id: typos
|
| 18 |
+
- repo: https://github.com/PyCQA/isort
|
| 19 |
+
rev: 6.0.1
|
| 20 |
+
hooks:
|
| 21 |
+
- id: isort
|
| 22 |
+
- repo: https://github.com/pre-commit/mirrors-clang-format
|
| 23 |
+
rev: v20.1.3
|
| 24 |
+
hooks:
|
| 25 |
+
- id: clang-format
|
| 26 |
+
types_or: [c++, cuda]
|
| 27 |
+
args: [--style=file, --verbose]
|
| 28 |
+
- repo: https://github.com/jackdewinter/pymarkdown
|
| 29 |
+
rev: v0.9.29
|
| 30 |
+
hooks:
|
| 31 |
+
- id: pymarkdown
|
| 32 |
+
args: [fix]
|
| 33 |
+
- repo: https://github.com/rhysd/actionlint
|
| 34 |
+
rev: v1.7.7
|
| 35 |
+
hooks:
|
| 36 |
+
- id: actionlint
|