-
Notifications
You must be signed in to change notification settings - Fork 2
/
.pre-commit-config.yaml
62 lines (55 loc) · 1.73 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
62
default_language_version:
python: python3
repos:
- repo: https://github.com/alessandrojcm/commitlint-pre-commit-hook
rev: 'v9.15.0'
hooks:
- id: commitlint
stages: [commit-msg]
additional_dependencies: ['@commitlint/config-conventional']
- repo: https://github.com/psf/black
rev: 24.3.0
hooks:
- id: black
- repo: https://github.com/pre-commit/mirrors-mypy
rev: 'v1.9.0' # Use the sha / tag you want to point at
hooks:
- id: mypy
files: "^src/kiara"
pass_filenames: true
args: ["--config-file", "pyproject.toml"]
additional_dependencies: [pydantic>=2.0.0, pydantic_settings, rich>=10.0.0, ruamel.yaml, anyio>=3.0.0, pyzmq>=22.0.3, bidict, sqlalchemy-stubs, types-python-slugify, types-setuptools, types-python-dateutil, dag_cbor>=0.3.0, multiformats>=0.2.0, textual, regex, types-pytz, types-orjson, dag_cbor>=0.3.2]
- repo: https://github.com/astral-sh/ruff-pre-commit
# Ruff version.
rev: v0.4.1
hooks:
# Run the linter.
- id: ruff
args: [ --fix ]
# Run the formatter.
# - id: ruff-format
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: 'v4.5.0'
hooks:
- id: trailing-whitespace
exclude: '(setup.cfg|src/kiara/utils/cli/__init__.py)'
- id: check-added-large-files
- id: check-ast
- id: check-json
- id: check-merge-conflict
- id: check-xml
- id: check-yaml
exclude: '(tests/\*|ci/conda/kiara/meta.yaml)'
- id: debug-statements
- id: end-of-file-fixer
exclude: '(.*.json|.*.j2)'
- id: requirements-txt-fixer
- id: fix-encoding-pragma
- id: mixed-line-ending
args: ['--fix=no']
- id: no-commit-to-branch
args: [--branch, main]
- repo: https://github.com/Kludex/no-optional
rev: 0.4.0
hooks:
- id: no_optional