-
Notifications
You must be signed in to change notification settings - Fork 251
Expand file tree
/
Copy path.pre-commit-config.yaml
More file actions
77 lines (77 loc) · 2.35 KB
/
.pre-commit-config.yaml
File metadata and controls
77 lines (77 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
71
72
73
74
75
76
77
# See https://pre-commit.com for more information
default_stages: [pre-commit]
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v3.2.0
hooks:
- id: trailing-whitespace
- id: end-of-file-fixer
- id: check-yaml
- id: check-added-large-files
- repo: https://github.com/pycqa/isort
rev: 5.13.2
hooks:
# Run isort to check only (don't modify files)
- id: isort
name: "Check imports are sorted"
args: [--check-only, --filter-files]
stages: [pre-commit]
- repo: https://github.com/astral-sh/ruff-pre-commit
# Ruff version.
rev: v0.14.4
hooks:
# Run the linter to check only (don't modify files)
- id: ruff-check
name: "Check code is linted with ruff"
- repo: https://github.com/PyCQA/flake8
rev: 7.3.0
hooks:
- id: flake8
name: "Check code is linted with flake8"
additional_dependencies: [flake8-pyproject]
- repo: https://github.com/crate-ci/typos
rev: v1.39.1
hooks:
- id: typos
name: "Check files for typos"
stages: [pre-commit]
- repo: https://github.com/rhysd/actionlint
rev: v1.7.8
hooks:
- id: actionlint-docker
args: [-oneline]
- repo: https://github.com/hadolint/hadolint
rev: v2.12.0
hooks:
- id: hadolint-docker
entry: -e HADOLINT_IGNORE=DL3003,DL3004,DL3005,DL3007,DL3008,DL3009,DL3013,DL3015,DL3042,DL3059,SC2103,SC2046,SC2086 ghcr.io/hadolint/hadolint hadolint
#
# These stages modify the files applying fixes where possible
# Since this may be undesirable they will not run automatically
# These stages can be run with
# pre-commit run --hook-stage manual
#
- repo: https://github.com/pycqa/isort
rev: 5.13.2
hooks:
# Run isort to check only (don't modify files)
- id: isort
name: "Fix imports with isort"
args: [--filter-files]
stages: [manual]
- repo: https://github.com/astral-sh/ruff-pre-commit
# Ruff version.
rev: v0.14.4
hooks:
# Run the linter to check only (don't modify files)
- id: ruff-check
name: "Fix linting errors with ruff check --fix"
args: [--fix]
stages: [manual]
- repo: https://github.com/crate-ci/typos
rev: v1.39.1
hooks:
- id: typos
name: "Fix typos"
args: [-w]
stages: [manual]