Spaces:
Sleeping
Sleeping
File size: 1,262 Bytes
7af929b |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 |
# This file defines common tasks that most python projects can benefit from
[tool.poe.tasks.format-isort]
help = "Format code with isort"
cmd = "isort ."
[tool.poe.tasks.format-black]
help = "Format code with black"
cmd = "black ."
[tool.poe.tasks.format]
help = "Run code formating tools"
sequence = ["format-isort", "format-black"]
[tool.poe.tasks.style-black]
help = "Validate black code style"
cmd = "black . --check --diff"
[tool.poe.tasks.style-isort]
help = "Validate isort code style"
cmd = "isort . --check --diff"
[tool.poe.tasks.style]
help = "Validate code style"
sequence = ["style-isort", "style-black"]
[tool.poe.tasks.types]
help = "Run the type checker"
cmd = "mypy . --ignore-missing-imports --check-untyped-defs --install-types --non-interactive"
[tool.poe.tasks.lint]
help = "Evaluate ruff rules"
cmd = "ruff check ."
[tool.poe.tasks.test]
help = "Run unit tests"
cmd = "pytest -p no:cacheprovider"
[tool.poe.tasks.clean]
help = "Remove automatically generated files"
cmd = """
rm -rf dist
.mypy_cache
.pytest_cache
.ruff_cache
./**/__pycache__/
./**/*.pyc
"""
[tool.poe.tasks.check]
help = "Run all checks on the code base"
sequence = ["style", "types", "lint", "clean"] |