-
Notifications
You must be signed in to change notification settings - Fork 212
Expand file tree
/
Copy path.pre-commit-config.yaml
More file actions
64 lines (64 loc) · 1.82 KB
/
.pre-commit-config.yaml
File metadata and controls
64 lines (64 loc) · 1.82 KB
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
63
64
---
exclude: '^atorch/|^tfplus/^|xpu_timer/'
repos:
- repo: https://github.com/astral-sh/ruff-pre-commit
# Ruff version.
rev: v0.12.3
hooks:
# Run the linter.
- id: ruff-check
args: [--fix]
exclude: dlrover/proto/|examples
# Run the formatter.
- id: ruff-format
args: [--line-length=79]
- repo: https://github.com/pre-commit/mirrors-mypy
rev: v1.16.1
hooks:
- id: mypy
args:
- --ignore-missing-imports
- --follow-imports=skip
- --disable-error-code=import-untyped
exclude: dlrover/proto/|examples
- repo: local
hooks:
- id: clang-format
name: clang-format
description: Format files with ClangFormat.
entry: bash ./scripts/codestyle/clang_format.hook -i
language: system
files: \.(c|cc|cxx|cpp|cu|h|hpp|hxx|proto)$
- repo: local
hooks:
- id: cpplint-cpp-source
name: cpplint
description: Check C++ code style using cpplint.py.
entry: bash ./scripts/codestyle/cpplint_precommit.hook
language: system
files: \.(c|cc|cxx|cpp|cu|h|hpp|hxx)$
- repo: https://github.com/dnephin/pre-commit-golang.git
rev: v0.5.1
hooks:
- id: go-fmt
- id: go-lint
- id: no-go-testing
- repo: https://github.com/gruntwork-io/pre-commit
rev: v0.1.30
hooks:
- id: shellcheck
files: \.(sh)$
- repo: local
hooks:
- id: copyright_checker
name: copyright_checker
entry: python ./scripts/codestyle/copyright.py
language: system
files: \.(go|py|sh)$
exclude: \.(deepcopy.go|pb.go)$
- repo: https://github.com/adrienverge/yamllint.git
rev: v1.37.1
hooks:
- id: yamllint
exclude:
(dlrover/python/tests/data|go/elasticjob/config)