Files
id_configurator/.pre-commit-config.yaml
T
2026-10-05 20:46:38 +02:00

106 lines
4.0 KiB
YAML

# 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: v6.0.0
hooks:
- id: check-added-large-files
exclude: ^(id_tests/.*/data/.*|npm/node_modules/.*|doc/_static/.*|doc/_static/videos/.*|uv.lock)
- id: check-docstring-first
exclude: ^(id_tests/.*/data/.*|npm/node_modules/.*)
- id: end-of-file-fixer
exclude: ^(id_tests/.*/data/.*|npm/node_modules/.*)
- id: fix-byte-order-marker
exclude: ^(id_tests/.*/data/.*|npm/node_modules/.*)
- id: check-ast
exclude: ^(id_tests/.*/data/.*|npm/node_modules/.*)
- id: check-case-conflict
exclude: ^(id_tests/.*/data/.*|npm/node_modules/.*)
- id: check-executables-have-shebangs
exclude: ^(id_tests/.*/data/.*|templates/id_tests/.*|npm/node_modules/.*)
- id: check-json
exclude: ^(id_tests/.*/data/.*|npm/node_modules/.*)
- id: check-merge-conflict
exclude: ^(id_tests/.*/data/.*|npm/node_modules/.*)
- id: check-toml
exclude: ^(id_tests/.*/data/.*|npm/node_modules/.*)
- id: check-yaml
exclude: ^(id_tests/.*/data/.*|npm/node_modules/.*)
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.12.11
hooks:
- id: ruff
args: [--fix]
exclude: ^(id_tests/.*/data/.*|npm/node_modules/.*)
- id: ruff-format
exclude: ^(id_tests/.*/data/.*|npm/node_modules/.*)
- repo: https://github.com/pre-commit/pygrep-hooks
rev: v1.10.0
hooks:
- id: rst-inline-touching-normal
exclude: ^(id_tests/.*/data/.*|npm/node_modules/.*)
- id: rst-directive-colons
exclude: ^(id_tests/.*/data/.*|npm/node_modules/.*)
- id: rst-backticks
exclude: ^(id_tests/.*/data/.*|npm/node_modules/.*)
- id: python-no-log-warn
exclude: ^(id_tests/.*/data/.*|npm/node_modules/.*)
- id: python-no-eval
exclude: ^(id_tests/.*/data/.*|npm/node_modules/.*)
- id: python-check-mock-methods
exclude: ^(id_tests/.*/data/.*|npm/node_modules/.*)
- id: python-check-blanket-noqa
exclude: ^(id_tests/.*/data/.*|npm/node_modules/.*)
- repo: https://github.com/thibaudcolas/pre-commit-stylelint
rev: v16.23.1
hooks:
- id: stylelint
args: [--config, .stylelintrc.json]
exclude: ^(id_tests/.*/data/.*|npm/node_modules/.*|interdiode/static/vendor/.*|interdiode/static/css/.*)
additional_dependencies:
- stylelint-scss
- stylelint-config-standard
- stylelint-config-standard-scss
- repo: https://github.com/pre-commit/mirrors-eslint
rev: v9.34.0
hooks:
- id: eslint
args: [--fix, -c, npm/eslint.config.mjs]
exclude: ^(id_tests/.*/data/.*|npm/node_modules/.*|interdiode/static/vendor/.*|interdiode/static/js/.*)
- repo: https://github.com/commitizen-tools/commitizen
rev: v4.8.3
hooks:
- id: commitizen
args: []
exclude: ^(id_tests/.*/data/.*|npm/node_modules/.*)
- repo: https://github.com/PyCQA/bandit
rev: 1.8.6
hooks:
- id: bandit
args: [-s, 'B101,B105,B404,B405,B506,B703,B308,B603,B604']
exclude: ^(id_tests/.*|npm/node_modules/.*|tools/.*|doc/.*|interdiode/static/vendor/.*)
- repo: https://github.com/shellcheck-py/shellcheck-py
rev: v0.11.0.1
hooks:
- id: shellcheck
exclude: ^(id_tests/.*|npm/node_modules/.*|.*/templates/id_tests/.*|tools/.*|doc/.*)
- repo: https://github.com/d9pouces/mybestpractices
rev: 0.3.8
hooks:
- id: mybestpractices-git-autotag
args: [--only-branch, 'dev,master']
- repo: https://github.com/macisamuele/language-formatters-pre-commit-hooks
rev: v2.15.0
hooks:
- id: pretty-format-ini
args: [--autofix]
exclude: ^(id_tests/.*/data/.*|npm/node_modules/.*|interdiode/static/vendor/.*|interdiode/static/js/.*)
- id: pretty-format-toml
args: [--autofix]
exclude: ^(id_tests/.*/data/.*|npm/node_modules/.*|interdiode/static/vendor/.*|interdiode/static/js/.*)
- id: pretty-format-yaml
args: [--autofix, --preserve-quotes]
exclude: ^(id_tests/.*/data/.*|npm/node_modules/.*|interdiode/static/vendor/.*|interdiode/static/js/.*|tools/docker/docker-compose.yml)
default_language_version:
python: python3.13