generated from ioxio-dataspace/definitions-template
-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy path.pre-commit-config.yaml
61 lines (61 loc) · 1.85 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
# See https://pre-commit.com for more information
# See https://pre-commit.com/hooks.html for more hooks
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.6.0
hooks:
- id: trailing-whitespace
- id: end-of-file-fixer
- id: check-merge-conflict
- id: debug-statements
# All non-bat files should end with LF
- id: mixed-line-ending
name: Ensure LF endings on most files
args: ["--fix=lf"]
exclude: \.bat$
# Bat files should end with CRLF
- id: mixed-line-ending
name: Ensure CFLF endings on Windows files
args: ["--fix=crlf"]
files: \.bat$
- repo: https://github.com/shellcheck-py/shellcheck-py
rev: v0.10.0.1
hooks:
- id: shellcheck
- repo: https://github.com/ioxio-dataspace/ioxio-data-product-definition-tooling
rev: 0.9.0
hooks:
- id: data-product-definition-converter
# TODO: convert only the file that was changed
pass_filenames: false
args: ["src", "DataProducts"]
files: |
(?x)^(
DataProducts/.*json|
src/.*py
)$
- repo: https://github.com/pre-commit/mirrors-prettier
rev: v2.7.1
hooks:
- id: prettier
- repo: https://github.com/PyCQA/isort
rev: 5.13.2
hooks:
- id: isort
- repo: https://github.com/psf/black
rev: 24.4.2
hooks:
- id: black
language_version: python3
- repo: https://github.com/ioxiocom/openapi-to-fastapi
rev: 0.17.0
hooks:
- id: openapi-validator
files: ".*?DataProducts/.*?json$"
args: ["--path", "./DataProducts"]
- repo: https://github.com/ioxio-dataspace/ioxio-data-product-definition-tooling
rev: 0.9.0
hooks:
- id: data-product-definition-validator
files: ".*?DataProducts/.*?json$"
args: ["./DataProducts"]