forked from theochem/Selector
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.pre-commit-hooks.yaml
84 lines (73 loc) · 2.35 KB
/
.pre-commit-hooks.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
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
# https://github.com/pre-commit/pre-commit-hooks/blob/main/.pre-commit-hooks.yaml
- id: trailing-whitespace
name: trim trailing whitespace
description: trims trailing whitespace.
entry: trailing-whitespace-fixer
language: python
types: [text]
# exclude: ^(book|devtools|docs|doc)/
stages: [commit, push, manual]
- id: sort-simple-yaml
name: sort simple yaml files
description: sorts simple yaml files which consist only of top-level keys, preserving comments and blocks.
language: python
entry: sort-simple-yaml
files: '^$'
- id: black
name: black
description: "Black: The uncompromising Python code formatter"
entry: black
language: python
minimum_pre_commit_version: 3.4.0
require_serial: true
types_or: [python, pyi]
- id: check-toml
name: check toml
description: checks toml files for parseable syntax.
entry: check-toml
language: python
types: [toml]
- id: check-yaml
name: check yaml
description: checks yaml files for parseable syntax.
entry: check-yaml
language: python
# exclude: ^website.yml
types: [yaml]
- id: requirements-txt-fixer
name: fix requirements.txt
description: sorts entries in requirements.txt.
entry: requirements-txt-fixer
language: python
files: (requirements|constraints).*\.txt$
- id: mixed-line-ending
name: mixed line ending
description: replaces or checks mixed line ending.
entry: mixed-line-ending
language: python
types: [text]
- id: end-of-file-fixer
name: fix end of files
description: ensures that a file is either empty, or ends with one newline.
entry: end-of-file-fixer
language: python
types: [python]
stages: [commit, push, manual]
- id: debug-statements
name: debug statements (python)
description: checks for debugger imports and py37+ `breakpoint()` calls in python source.
entry: debug-statement-hook
language: python
types: [python]
- id: check-merge-conflict
name: check for merge conflicts
description: checks for files that contain merge conflict strings.
entry: check-merge-conflict
language: python
types: [text]
- id: check-ast
name: check python ast
description: simply checks whether the files parse as valid python.
entry: check-ast
language: python
types: [python]