-
Notifications
You must be signed in to change notification settings - Fork 0
/
.pre-commit-config.yaml
62 lines (62 loc) · 1.71 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
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
repos:
- repo: https://github.com/psf/black
rev: 22.3.0
hooks:
- id: black
- repo: local
hooks:
- id: pylint
name: pylint
entry: bash -c 'pylint "$@" || true' --
verbose: true
language: system
exclude: rst-dir
types: [python]
args: ["--good-names-rgxs=^[_a-z][_a-z0-9]?$",
"--max-args=10",
"--min-similarity-lines=30"]
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.1.0
hooks:
- id: trailing-whitespace
- id: end-of-file-fixer
exclude: thirdparty/.*$
- id: check-yaml
- id: check-json
- repo: https://github.com/Lucas-C/pre-commit-hooks
rev: v1.1.13
hooks:
- id: insert-license
files: \.(h|cpp|proto)$
exclude: thirdparty/.*$
args:
- --comment-style
- //
- --license-filepath
- license_header.txt
- repo: https://github.com/pre-commit/mirrors-clang-format
rev: v14.0.0
hooks:
- id: clang-format
files: \.(h|cpp)
exclude: (thirdparty)/.*$
- repo: local
hooks:
- id: pragma-once
name: pragma once check
entry: "#pragma once"
language: pygrep
exclude: thirdparty/.*$
files: \.h$
args: [--negate]
- id: no-c-std-lib
name: c standard library check
exclude: thirdparty/.*$
entry: |
(?x)<(
assert|complex|ctype|errno|fenv|float|inttypes|iso646|limits|locale|math|setjmp|signal|
stdalign|stdarg|stdatomic|stdbool|stddef|stdint|stdio|stdlib|stdnoreturn|string|tgmath|
threads|time|uchar|wchar|wctype
).h>
language: pygrep
files: \.(h|cpp)$