-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy path.pre-commit-config.yaml
64 lines (64 loc) · 1.81 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
63
64
# .pre-commit-config.yaml
repos:
- repo: https://github.com/pre-commit/mirrors-prettier
rev: v2.4.1
hooks:
- id: prettier
name: Yaml formatting using prettier
- repo: local
hooks:
- id: black
name: Code formatting using black
description: Format code using black
entry: poetry run black
language: system
types: [python]
require_serial: true
- id: flake8
name: Linting using flake8
description: Use flake8 for code improvements.
entry: poetry run flake8
language: system
types: [python]
require_serial: true
- id: check-toml
name: Check Toml
entry: check-toml
language: system
types: [toml]
- id: check-yaml
name: Check Yaml
entry: check-yaml
language: system
types: [yaml]
- id: end-of-file-fixer
name: Fix End of Files
entry: end-of-file-fixer
language: system
types: [text]
stages: [commit, push, manual]
- id: pyupgrade
name: pyupgrade
description: Automatically upgrade syntax for newer versions.
entry: poetry run pyupgrade
language: system
types: [python]
args: [--py310-plus]
- id: isort
name: Sort python imports using isort through poetry.
entry: poetry run isort
language: system
types: [python]
args: [-v]
- id: trailing-whitespace
name: Trim Trailing Whitespace
entry: trailing-whitespace-fixer
language: system
types: [text]
stages: [commit, push, manual]
- id: pylint
name: Linting using pylint
entry: poetry run pylint
language: system
types: [python]
args: [--output-format=colorized]