-
Notifications
You must be signed in to change notification settings - Fork 0
/
.pre-commit-config.yaml
57 lines (56 loc) · 1.55 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
# Use `|` to concat the other folder path
files: ^app|.github/workflows
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.0.1
hooks:
- id: check-docstring-first
- id: check-toml
- id: check-yaml
exclude: packaging/.*
- id: mixed-line-ending
args: [--fix=lf]
- id: end-of-file-fixer
- repo: https://github.com/omnilib/ufmt
rev: v1.3.2
hooks:
- id: ufmt
additional_dependencies:
- black == 22.3.0
- usort == 1.0.2
- repo: https://github.com/lovesegfault/beautysh
rev: v6.2.1
hooks:
- id: beautysh
- repo: https://github.com/myint/autoflake
rev: v1.4
hooks:
- id: autoflake
args:
- --in-place
- --remove-unused-variables
- --remove-all-unused-imports
- repo: https://github.com/pycqa/pylint
rev: v3.0.0a6
hooks:
- id: pylint
# Remove unused import
args: ["--enable=W0614"]
- repo: local
hooks:
- id: fetch-changed-infer-path
name: Fetch changed inference logic path
entry: .ci/fetch-changed-infer.sh
language: script
files: ^inference/
# - repo: https://github.com/PyCQA/pydocstyle
# rev: 6.1.1
# hooks:
# - id: pydocstyle
# additional_dependencies: ["toml"]
- repo: https://github.com/jumanjihouse/pre-commit-hook-yamlfmt
rev: 0.2.3
hooks:
- id: yamlfmt
args: [--mapping, '2', --sequence, '2', --offset, '0']
files: .github/workflows/.* # Only format workflow files