forked from sartography/spiff-arena
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.pre-commit-config.yaml
68 lines (66 loc) · 2.17 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
65
66
67
68
repos:
- repo: local
hooks:
- id: black
name: black
# entry: bash -c 'cd spiffworkflow-backend && black'
entry: black
language: system
files: ^spiffworkflow-backend/
types: [python]
require_serial: true
# exclude: ^migrations/
exclude: "/migrations/"
# --preview because otherwise it will not fix long lines if the long lines contain long strings
# https://github.com/psf/black/pull/1132
# https://github.com/psf/black/pull/1609
# --line-length because then we can avoid the fancy line wrapping in more instances and jason, kb, and elizabeth
# kind of prefer long lines rather than cutely-formatted sets of lines.
# TODO: enable when its safe to update the files
args: [--preview, --line-length, "119"]
- id: check-added-large-files
files: ^spiffworkflow-backend/
name: Check for added large files
entry: check-added-large-files
language: system
- id: check-toml
files: ^spiffworkflow-backend/
name: Check Toml
entry: check-toml
language: system
types: [toml]
- id: check-yaml
files: ^spiffworkflow-backend/
name: Check Yaml
entry: check-yaml
language: system
types: [yaml]
- id: end-of-file-fixer
files: ^spiffworkflow-backend/
name: Fix End of Files
entry: end-of-file-fixer
language: system
types: [text]
stages: [commit, push, manual]
- id: ruff
files: ^spiffworkflow-backend/
name: ruff
entry: ruff
language: system
types: [python]
require_serial: true
exclude: "/migrations/"
- id: trailing-whitespace
files: ^spiffworkflow-backend/
name: Trim Trailing Whitespace
entry: trailing-whitespace-fixer
language: system
types: [text]
stages: [commit, push, manual]
exclude: "/migrations/"
# - repo: https://github.com/pre-commit/mirrors-prettier
# rev: v2.4.1
# hooks:
# - id: prettier
# files: ^spiffworkflow-backend/
# exclude_types: [html]