Python-Skelett, Werkzeuge und CI #5

Merged
torben merged 3 commits from 1-skeleton-tooling-ci into main 2026-12-01 22:09:10 +00:00
2 changed files with 66 additions and 0 deletions
Showing only changes of commit 7c1567e4ec - Show all commits

No files matched your search

+42
View File
@@ -0,0 +1,42 @@
# All hooks are local and run through `uv run`, so every tool version comes
# from uv.lock only. No remote hook repositories, nothing is downloaded by
# pre-commit itself.
repos:
- repo: local
hooks:
- id: ruff-check
name: ruff check
entry: uv run ruff check --fix
language: system
types_or: [python, pyi]
- id: ruff-format
name: ruff format
entry: uv run ruff format
language: system
types_or: [python, pyi]
- id: check-yaml
name: check yaml
entry: uv run check-yaml
language: system
types: [yaml]
- id: check-toml
name: check toml
entry: uv run check-toml
language: system
types: [toml]
- id: end-of-file-fixer
name: fix end of files
entry: uv run end-of-file-fixer
language: system
types: [text]
- id: trailing-whitespace
name: trim trailing whitespace
entry: uv run trailing-whitespace-fixer
language: system
types: [text]
- id: uv-lock-check
name: uv lock --check
entry: uv lock --check
language: system
files: ^(pyproject\.toml|uv\.lock)$
pass_filenames: false
+24
View File
@@ -25,3 +25,27 @@ dev = [
[tool.uv]
exclude-newer = "7 days"
[tool.ruff]
target-version = "py314"
line-length = 100
src = ["src", "tests"]
[tool.ruff.lint]
select = ["E", "W", "F", "I", "B", "UP", "SIM", "RUF", "PT", "N", "S", "C4", "PTH", "RET"]
[tool.ruff.lint.per-file-ignores]
"tests/**" = ["S101"]
[tool.pyright]
include = ["src", "tests"]
typeCheckingMode = "strict"
pythonVersion = "3.14"
venvPath = "."
venv = ".venv"
[tool.pytest.ini_options]
minversion = "9.0"
testpaths = ["tests"]
addopts = ["-ra", "--strict-markers", "--strict-config"]
xfail_strict = true