-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.pre-commit-config.yaml
More file actions
56 lines (53 loc) · 1.46 KB
/
.pre-commit-config.yaml
File metadata and controls
56 lines (53 loc) · 1.46 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
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v5.0.0
hooks:
- id: trailing-whitespace
- id: end-of-file-fixer
- id: check-yaml
exclude: ^deploy/helm/
- id: check-json
exclude: ^frontend/tsconfig
- id: check-added-large-files
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.9.6
hooks:
- id: ruff
args: [--fix]
- id: ruff-format
- repo: https://github.com/PyCQA/bandit
rev: "1.8.3"
hooks:
- id: bandit
args: [-r, src/, -c, pyproject.toml]
pass_filenames: false
- repo: local
hooks:
- id: frontend-eslint
name: frontend-eslint
entry: bash -c 'cd frontend && npx eslint src'
language: system
types_or: [ts, tsx]
files: ^frontend/src/
pass_filenames: false
- id: frontend-tsc
name: frontend-tsc
entry: bash -c 'cd frontend && npx tsc -b --noEmit'
language: system
types_or: [ts, tsx]
files: ^frontend/src/
pass_filenames: false
- id: backend-tests
name: backend-tests
entry: pytest -v
language: system
pass_filenames: false
always_run: true
stages: [pre-push]
- id: frontend-tests
name: frontend-tests
entry: bash -c 'cd frontend && npm test'
language: system
pass_filenames: false
always_run: true
stages: [pre-push]