diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 1dd2b11..55bb18f 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -15,15 +15,11 @@ repos: - id: check-symlinks - id: check-json - - repo: https://github.com/psf/black - rev: 24.8.0 - hooks: - - id: black - - repo: https://github.com/charliermarsh/ruff-pre-commit rev: "v0.6.8" hooks: - id: ruff + - id: ruff-format - repo: https://github.com/RobertCraigie/pyright-python rev: v1.1.382.post0 diff --git a/pyproject.toml b/pyproject.toml index 496449b..152b6ed 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -84,6 +84,11 @@ ignore = ["./tests/**/*"] [tool.ruff] target-version = "py38" line-length = 100 + +[tool.ruff.format] +exclude = ["**/migrations/*"] + +[tool.ruff.lint] select = [ "A", # flake8-builtins "ARG", # flake8-unused-arguments @@ -114,15 +119,16 @@ unfixable = [ "F841", ] -[tool.ruff.isort] -known-first-party = ["django_tailwind_cli"] +[tool.ruff.lint.isort] +known-first-party = ["solomon"] -[tool.ruff.flake8-tidy-imports] +[tool.ruff.lint.flake8-tidy-imports] ban-relative-imports = "all" -[tool.ruff.per-file-ignores] -"tests/**/*" = ["PLR2004", "S101", "TID252"] +[tool.ruff.lint.per-file-ignores] +"tests/**/*" = ["PLR2004", "S101", "TID252", "ARG001"] "tests/snapshots/*" = ["ALL"] +"**/migrations/*" = ["ALL"] # Pytest [tool.pytest.ini_options]