forked from activist-org/activist
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.pre-commit-config.yaml
More file actions
58 lines (52 loc) · 1.59 KB
/
.pre-commit-config.yaml
File metadata and controls
58 lines (52 loc) · 1.59 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
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v5.0.0
hooks:
# - id: trailing-whitespace # handled by Ruff and Prettier
- id: end-of-file-fixer
exclude: ^docs/|README.md$
- id: check-yaml
- id: check-added-large-files
# - id: pretty-format-json
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.11.10
hooks:
- id: ruff-check
name: run ruff linting check
files: ^backend/
args: [--fix, --exit-non-zero-on-fix]
- id: ruff-format
name: run ruff formatting check
files: ^backend/
- repo: https://github.com/numpy/numpydoc
rev: v1.8.0
hooks:
- id: numpydoc-validation
name: run numpydoc docstring validation
files: ^backend/
exclude: ^backend/(.*/?(tests(/.*)?|views\.py|__init__\.py))$
- repo: local
hooks:
- id: mypy-check
name: run mypy static type checking
files: ^backend/
entry: mypy ./backend --config-file ./backend/pyproject.toml
language: python
types: [python]
pass_filenames: false
- repo: local
hooks:
- id: run-i18n-check
name: run i18n-check key-value checks
files: ^frontend/
entry: i18n-check -a
language: python
pass_filenames: false
additional_dependencies:
- i18n-check
- id: prettier-eslint-checks
name: run prettier and eslint checks
files: ^frontend/
entry: python -m pre_commit_scripts.prettier_eslint_checks
language: python
pass_filenames: false