forked from Raptor123471/DingoLingo
-
Notifications
You must be signed in to change notification settings - Fork 18
/
Copy path.pre-commit-config.yaml
38 lines (34 loc) · 1.08 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
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
- id: check-added-large-files
- repo: https://github.com/psf/black
rev: 25.1.0
hooks:
- id: black
args: ["-l", "79"]
- repo: https://github.com/pycqa/flake8
rev: 7.1.2
hooks:
- id: flake8
args: ["--ignore", "E203,W503"]
- repo: local
hooks:
- id: check-jsonc
name: check-jsonc
description: 'Check JSON with comments'
entry: python -c 'import os, sys; os.system("pip install ./config"); import jsonc; jsonc.load(open(sys.argv[1]))'
language: python
types: [json]
require_serial: true
- id: update-dockerfile
name: update-dockerfile
description: 'Update env vars in Dockerfile'
entry: python -c 'import os, runpy; os.system("pip install ./config"); runpy.run_path("config/update-dockerfile.py")'
files: ^config/config\.py$
language: python
require_serial: true