mirror of
https://github.com/unshackle-dl/unshackle.git
synced 2026-11-12 20:15:10 +00:00
Pre-commit runs ruff, isort and bandit through uv run, so it uses the versions in uv.lock. Bandit moves from runtime dependencies to the dev group.
50 lines
1.4 KiB
YAML
50 lines
1.4 KiB
YAML
# See https://pre-commit.com for more information
|
|
# See https://pre-commit.com/hooks.html for more hooks
|
|
|
|
exclude: ^tests/fixtures/manifests/
|
|
repos:
|
|
- repo: https://github.com/compilerla/conventional-pre-commit
|
|
rev: v4.4.0
|
|
hooks:
|
|
- id: conventional-pre-commit
|
|
stages: [commit-msg]
|
|
- repo: https://github.com/pre-commit/pre-commit-hooks
|
|
rev: v6.0.0
|
|
hooks:
|
|
- id: end-of-file-fixer
|
|
- id: trailing-whitespace
|
|
args: [--markdown-linebreak-ext=md]
|
|
- repo: local
|
|
hooks:
|
|
- id: ruff-check
|
|
name: ruff check
|
|
entry: uv run ruff check --fix
|
|
language: system
|
|
types: [python]
|
|
require_serial: true
|
|
- id: ruff-format
|
|
name: ruff format
|
|
entry: uv run ruff format
|
|
language: system
|
|
types: [python]
|
|
require_serial: true
|
|
- id: isort
|
|
name: isort
|
|
entry: uv run isort
|
|
language: system
|
|
types: [python]
|
|
require_serial: true
|
|
- id: bandit
|
|
name: bandit
|
|
entry: uv run bandit -q -c pyproject.toml --severity-level medium --confidence-level medium
|
|
language: system
|
|
types: [python]
|
|
files: ^unshackle/
|
|
- id: mypy
|
|
name: mypy
|
|
entry: uv run mypy unshackle
|
|
language: system
|
|
types: [python]
|
|
files: ^unshackle/
|
|
pass_filenames: false
|