-
-
Notifications
You must be signed in to change notification settings - Fork 21
/
Copy path.pre-commit-config.yaml
80 lines (74 loc) · 3.1 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
69
70
71
72
73
74
75
76
77
78
79
80
repos:
# lint yaml, line and whitespace
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: cef0300fd0fc4d2a87a85fa2093c6b283ea36f4b # frozen: v5.0.0
hooks:
- id: check-yaml
exclude: ^(rootfs/webapp/|acarshub-typescript/node_modules/)
- id: end-of-file-fixer
exclude: ^(rootfs/webapp/|acarshub-typescript/node_modules/)
- id: trailing-whitespace
exclude: ^(rootfs/webapp/|acarshub-typescript/node_modules/)
- id: requirements-txt-fixer
exclude: ^(acarshub-typescript/node_modules/)
- id: mixed-line-ending
exclude: ^(rootfs/webapp/|acarshub-typescript/node_modules/)
- id: check-executables-have-shebangs
exclude: ^(rootfs/webapp/|acarshub-typescript/node_modules/|acarshub-typescript/src)
- id: check-shebang-scripts-are-executable
exclude: ^(rootfs/webapp/|acarshub-typescript/node_modules/)
# lint the dockerfiles
- repo: https://github.com/hadolint/hadolint
rev: c3dc18df7a501f02a560a2cc7ba3c69a85ca01d3 # frozen: v2.13.1-beta
hooks:
- id: hadolint
exclude: ^(rootfs/webapp/|acarshub-typescript/node_modules/)
# lint python formatting
- repo: https://github.com/psf/black
rev: 8a737e727ac5ab2f1d4cf5876720ed276dc8dc4b # frozen: 25.1.0
hooks:
- id: black
- repo: https://github.com/pycqa/flake8
rev: "4b5e89b4b108a6c1a000c591d334a99a80d34c7b" # frozen: 7.2.0
hooks:
- id: flake8
args: ["--extend-ignore=W503,W504,E501,F824"]
# prettier
- repo: https://github.com/pre-commit/mirrors-prettier
rev: "f12edd9c7be1c20cfa42420fd0e6df71e42b51ea" # frozen: v4.0.0-alpha.8
hooks:
- id: prettier
types_or: [file, bash, sh, javascript, jsx, ts, tsx]
additional_dependencies:
- "@typescript-eslint/eslint-plugin"
# - "prettier-plugin-sh"
exclude: ^(rootfs/webapp/|acarshub-typescript/node_modules/|Dockerfile*)
- repo: https://github.com/pre-commit/mirrors-eslint
rev: 3209d7180d0506d898c3492456bbe7faae8de355 # frozen: v9.25.0
hooks:
- id: eslint
files: \.[j]sx?$ # *.js, *.jsx, *.ts and *.tsx
types: [file]
exclude: ^(rootfs/webapp/|acarshub-typescript/node_modules/)
additional_dependencies:
- "@typescript-eslint/eslint-plugin"
- repo: https://github.com/codespell-project/codespell.git
rev: "63c8f8312b7559622c0d82815639671ae42132ac" # frozen: v2.4.1
hooks:
- id: codespell
types: [text]
exclude: ^(rootfs/webapp/|acarshub-typescript/node_modules/|acarshub-typescript/package.json|acarshub-typescript/package-lock.json)
- repo: https://github.com/shellcheck-py/shellcheck-py
rev: a23f6b85d0fdd5bb9d564e2579e678033debbdff # frozen: v0.10.0.1
hooks:
- id: shellcheck
- repo: https://github.com/sirosen/check-jsonschema
rev: 06e4cc849d03f3a59ca223a4046f4bb5bb2aba6d # frozen: 0.33.0
hooks:
- id: check-github-actions
- id: check-github-workflows