-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.pre-commit-config.yaml
More file actions
60 lines (55 loc) · 1.71 KB
/
Copy path.pre-commit-config.yaml
File metadata and controls
60 lines (55 loc) · 1.71 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
exclude: 'node_modules|.git|^edu_quality/public/(walsh|ui|cmap-tool|dist)/|^edu_quality/www/(walsh|ui)\.html$|^edu_quality/docs/'
default_stages: [pre-commit]
fail_fast: false
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v5.0.0
hooks:
- id: trailing-whitespace
files: 'edu_quality.*'
exclude: '.*json$|.*txt$|.*csv|.*md|.*svg'
- id: check-merge-conflict
- id: check-ast
- id: check-json
exclude: 'tsconfig.*\.json$'
- id: check-toml
- id: check-yaml
- id: debug-statements
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.8.4
hooks:
- id: ruff
name: 'ruff import sort + lint (with fixes)'
args: ['--fix']
- id: ruff-format
name: 'ruff formatter'
- repo: https://github.com/pre-commit/mirrors-prettier
rev: v2.7.1
hooks:
- id: prettier
types_or: [javascript, ts, tsx, vue, scss, css]
exclude: |
(?x)^(
.*node_modules.*|
edu_quality/public/(walsh|ui|cmap-tool|dist)/.*|
edu_quality/public/js/lib/.*|
edu_quality/templates/includes/.*
)$
- repo: local
hooks:
- id: eslint-ui
name: 'eslint (ui)'
entry: bash -c 'cd ui && yarn --silent lint'
language: system
files: '^ui/src/.*\.(ts|tsx|js|jsx)$'
pass_filenames: false
- id: eslint-walsh
name: 'eslint (walsh)'
entry: bash -c 'cd walsh && yarn --silent lint'
language: system
files: '^walsh/src/.*\.(ts|tsx|js|jsx)$'
pass_filenames: false
ci:
autoupdate_schedule: weekly
skip: [eslint-ui, eslint-walsh]
submodules: false