-
Notifications
You must be signed in to change notification settings - Fork 0
/
.pre-commit-config.yaml
59 lines (53 loc) · 1.89 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
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.4.0
hooks:
# Linters
- id: check-added-large-files
- id: check-merge-conflict
- id: check-shebang-scripts-are-executable
- id: check-yaml
- id: mixed-line-ending
- id: pretty-format-json
args: [--indent=4]
# Fixers
- id: requirements-txt-fixer
- id: trailing-whitespace
- id: double-quote-string-fixer
- id: end-of-file-fixer
# Additional fixers:
# Automatically formats Python code to conform to the PEP 8 style guide.
- repo: https://github.com/pre-commit/mirrors-autopep8
rev: v2.0.4
hooks:
- id: autopep8
# Flake8 is a wrapper around these tools: PyFlakes, pycodestyle and Ned Batchelder's McCabe script. The combination
# of these three linters makes sure that your code is compliant with PEP 8 and free of some obvious code smells.
- repo: https://github.com/pycqa/flake8
rev: 6.1.0
hooks:
- id: flake8
name: Flake8
types: ['python']
# isort is a Python library to sort imports alphabetically, and automatically separated into sections and by type.
- repo: https://github.com/PyCQA/isort
rev: 5.12.0
hooks:
- id: isort
args: [--filter-files]
# Markdownlint is a static analysis tool with a library of rules to enforce standards and consistency for Markdown
# files.
- repo: https://github.com/igorshubovych/markdownlint-cli
rev: v0.36.0
hooks:
- id: markdownlint
args: [--fix]
# MyPy is Static Typing for Python
- repo: https://github.com/pre-commit/mirrors-mypy
rev: v1.5.1
hooks:
- id: MyPy
name: MyPy
args: [--config-file=mypy.ini]
exclude: ^setup.py|^tests/
types: ['python']