-
Notifications
You must be signed in to change notification settings - Fork 8
Expand file tree
/
Copy path.pre-commit-config.yaml
More file actions
70 lines (70 loc) · 2.35 KB
/
.pre-commit-config.yaml
File metadata and controls
70 lines (70 loc) · 2.35 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
65
66
67
68
69
70
# See https://pre-commit.com for more information
# See https://pre-commit.com/hooks.html for more hooks
repos:
- repo: https://github.com/alessandrojcm/commitlint-pre-commit-hook
rev: v2.2.0
hooks:
- id: commitlint
stages: [commit-msg]
additional_dependencies: ["@commitlint/config-conventional"]
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v3.2.0
hooks:
- id: check-merge-conflict
- id: check-json
- id: check-yaml
- id: end-of-file-fixer
- id: mixed-line-ending
args: [--fix=lf]
exclude: '.*\.bat'
- id: trailing-whitespace
args: [--markdown-linebreak-ext=md]
- id: check-added-large-files
- repo: https://github.com/pre-commit/pygrep-hooks
rev: v1.9.0
hooks:
- id: python-check-blanket-noqa
- id: python-check-blanket-type-ignore
- id: python-no-log-warn
- repo: local
hooks:
- id: flake8
name: Flake8
description: This hook runs flake8 within our project's poetry environment.
entry: poetry run pflake8
language: system
types: [python]
require_serial: true
- id: mypy
name: MyPy
description: This hook runs mypy within our project's poetry environment.
entry: poetry run mypy
language: system
types: [python]
require_serial: true
- id: isort
name: Isort
description: This hook runs isort within our project's poetry environment.
# https://github.com/pre-commit/pre-commit/issues/989
entry: poetry run isort --check-only
language: system
types: [python]
require_serial: true
- id: black
name: Black
description: This hook runs black within our project's pipenv environment.
# https://github.com/pre-commit/pre-commit/issues/989
entry: poetry run black --check
language: system
types: [python]
require_serial: true
- id: license_check
name: License Check
description: This hook checks if there are copyleft licenses in our repo.
# https://github.com/pre-commit/pre-commit/issues/989
entry: poetry run task license_check
language: system
files: ^(pyproject.toml|poetry.lock)$
types: [file]
require_serial: true
pass_filenames: false