-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.pre-commit-config.yaml
34 lines (34 loc) · 1.16 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
repos:
- repo: local
hooks:
- id: ruff
name: ruff
description: Format the code
entry: poetry run ruff format .
pass_filenames: false # run once per commit rather than file
language: system
- id: sort-imports
name: sort-imports
description: Keep imports in a nice sorted order
entry: ruff check --select I --fix
pass_filenames: false
language: system
# - id: mypy
# name: mypy
# description: Verify types statically
# entry: poetry run mypy
# pass_filenames: false
# language: system
- id: poetry
name: poetry
description: Validates the content of the pyproject.toml file and its consistency with the poetry.lock file
entry: poetry check
pass_filenames: false
language: system
- id: poetry-export-service
name: poetry-export
description: Exports requirements.txt file for docker container with service and web dependencies
entry: poetry export
args: [ "--with", "service,web", "-o", "requirements.txt" ]
pass_filenames: false
language: system