forked from morganzero/cloudflare-companion
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.pre-commit-config.yaml
More file actions
127 lines (112 loc) · 3.06 KB
/
.pre-commit-config.yaml
File metadata and controls
127 lines (112 loc) · 3.06 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
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
---
default_stages: [pre-commit]
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v5.0.0
hooks:
- id: trailing-whitespace
- id: check-added-large-files
- id: check-merge-conflict
- id: detect-private-key
- id: end-of-file-fixer
- id: check-yaml
- id: check-json
exclude: ^(.*/devcontainer\.json|\.vscode/.*)$
- id: pretty-format-json
exclude: ^(.*/devcontainer\.json|\.vscode/.*)$
args:
- --autofix
- --no-sort-keys
- --indent=4
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.6.5
hooks:
- id: ruff
name: Ruff linter
args: [--fix, --exit-non-zero-on-fix]
types_or: [python, pyi]
- id: ruff-format
name: Ruff format
types_or: [python, pyi]
- repo: https://github.com/codespell-project/codespell
rev: v2.3.0
hooks:
- id: codespell
additional_dependencies:
- tomli
args: [--ignore-words-list, astroid ]
- repo: https://github.com/Yelp/detect-secrets
rev: v1.5.0
hooks:
- id: detect-secrets
args: ['--baseline', '.secrets.baseline']
additional_dependencies: ["gibberish-detector"]
- repo: https://github.com/executablebooks/mdformat
rev: 0.7.17
hooks:
- id: mdformat
additional_dependencies:
- mdformat-ruff
- mdformat-tables
- mdformat-frontmatter
- mdformat-admon
- mdformat-wikilink
- repo: https://github.com/hadolint/hadolint
rev: v2.13.0-beta
hooks:
- id: hadolint
name: Lint Dockerfiles
description: Runs hadolint to lint Dockerfiles
language: system
types: ["dockerfile"]
entry: hadolint
- repo: https://github.com/econchick/interrogate
rev: 1.7.0 # or master if you're bold
hooks:
- id: interrogate
args: [--quiet, --fail-under=1]
exclude: test.*
- repo: local
hooks:
- id: taplo-lint
name: taplo lint
entry: taplo check
language: system
types: [toml]
- id: taplo-format
name: taplo format
entry: taplo format
language: system
types: [toml]
args:
- --option
- array_auto_collapse=false
- --option
- array_auto_expand=true
- --option
- allowed_blank_lines=1
- --option
- array_trailing_comma=true
- --option
- indent_entries=true
- --option
- indent_tables=true
- --option
- reorder_keys=true
- id: mypy
name: mypy static type checker
language: system
types: [python]
entry: uv run mypy
pass_filenames: false
- id: pyupgrade
name: Pyupgrade
entry: uv run pyupgrade --py312-plus
types: [python]
language: system
- id: deptry
name: Deptry
entry: uv run deptry src tests
types: [python]
language: system
pass_filenames: false