|
| 1 | +--- |
| 2 | +default_language_version: |
| 3 | + python: python3 |
1 | 4 | repos:
|
2 |
| -- repo: https://github.com/pre-commit/pre-commit-hooks |
3 |
| - rev: v3.2.0 |
| 5 | + - repo: https://github.com/pre-commit/pre-commit-hooks |
| 6 | + rev: v4.6.0 |
4 | 7 | hooks:
|
5 |
| - - id: check-ast |
6 |
| - - id: check-byte-order-marker |
7 |
| - - id: check-case-conflict |
8 |
| - - id: check-docstring-first |
9 |
| - - id: check-executables-have-shebangs |
10 |
| - - id: check-json |
11 |
| - - id: check-yaml |
12 |
| - exclude: ^chart/ |
13 |
| - - id: debug-statements |
14 |
| - - id: end-of-file-fixer |
| 8 | + - id: check-ast |
| 9 | + - id: check-byte-order-marker |
| 10 | + - id: check-case-conflict |
| 11 | + - id: check-docstring-first |
| 12 | + - id: check-json |
| 13 | + - id: check-yaml |
| 14 | + exclude: ^(chart/|docs/) |
| 15 | + - id: debug-statements |
| 16 | + - id: end-of-file-fixer |
15 | 17 | exclude: ^(docs/|gdocs/)
|
16 |
| - - id: pretty-format-json |
| 18 | + - id: pretty-format-json |
17 | 19 | args: ['--autofix']
|
18 |
| - - id: trailing-whitespace |
| 20 | + - id: trailing-whitespace |
| 21 | + args: ['--markdown-linebreak-ext=md'] |
19 | 22 | exclude: ^(docs/|gdocs/)
|
20 |
| - - id: mixed-line-ending |
| 23 | + - id: mixed-line-ending |
21 | 24 | args: ['--fix=lf']
|
22 | 25 | exclude: ^(docs/|gdocs/)
|
23 |
| -- repo: https://github.com/psf/black |
24 |
| - rev: 22.3.0 |
| 26 | + - id: check-added-large-files |
| 27 | + args: ['--maxkb=500'] |
| 28 | + - id: no-commit-to-branch |
| 29 | + args: ['--branch', 'master', '--branch', 'develop'] |
| 30 | + - repo: https://github.com/astral-sh/ruff-pre-commit |
| 31 | + rev: v0.5.2 |
25 | 32 | hooks:
|
26 |
| - - id: black |
27 |
| - args: [--line-length=120] |
28 |
| -- repo: https://github.com/pre-commit/mirrors-mypy |
29 |
| - rev: 'v0.941' |
| 33 | + - id: ruff |
| 34 | + args: [--fix] |
| 35 | + - id: ruff-format |
| 36 | + - repo: https://github.com/pre-commit/mirrors-mypy |
| 37 | + rev: 'v1.10.1' |
30 | 38 | hooks:
|
31 |
| - - id: mypy |
32 |
| - args: [--ignore-missing-imports, --show-error-codes] |
33 |
| - files: eurybia |
34 |
| - additional_dependencies: [types-PyYAML] |
35 |
| -- repo: https://github.com/PyCQA/flake8 |
36 |
| - rev: 4.0.1 |
| 39 | + - id: mypy |
| 40 | + args: [--config-file=pyproject.toml] |
| 41 | + files: src |
| 42 | +# Décommentez si vous utilisez pydantic (+ ajustez la version): |
| 43 | +# additional_dependencies: [pydantic~=1.0] |
| 44 | + - repo: https://github.com/pypa/pip-audit |
| 45 | + rev: v2.7.3 |
37 | 46 | hooks:
|
38 |
| - - id: flake8 |
39 |
| - exclude: ^tests/ |
40 |
| - args: ['--ignore=E501,D2,D3,D4,D104,D100,D106,D107,W503,D105,E203'] |
41 |
| - additional_dependencies: [flake8-docstrings] |
42 |
| -- repo: https://github.com/pre-commit/mirrors-isort |
43 |
| - rev: v5.4.2 |
| 47 | + - id: pip-audit |
| 48 | + args: [--skip-editable, --fix] |
| 49 | +# - repo: https://github.com/gitleaks/gitleaks |
| 50 | +# rev: v8.18.2 |
| 51 | +# hooks: |
| 52 | +# - id: gitleaks |
| 53 | + - repo: https://github.com/compilerla/conventional-pre-commit |
| 54 | + rev: v3.3.0 |
44 | 55 | hooks:
|
45 |
| - - id: isort |
46 |
| - args: ["--profile", "black", "-l", "120"] |
47 |
| -- repo: https://github.com/asottile/pyupgrade |
48 |
| - rev: v2.7.2 |
49 |
| - hooks: |
50 |
| - - id: pyupgrade |
51 |
| - args: [--py37-plus] |
52 |
| -- repo: https://github.com/asottile/blacken-docs |
53 |
| - rev: v1.8.0 |
54 |
| - hooks: |
55 |
| - - id: blacken-docs |
56 |
| - additional_dependencies: [black==21.12b0] |
| 56 | + - id: conventional-pre-commit |
| 57 | + stages: [commit-msg] |
| 58 | + args: [] # optional: list of Conventional Commits types to allow e.g. [feat, fix, ci, chore, test] |
0 commit comments