-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpyproject.toml
82 lines (67 loc) · 1.71 KB
/
pyproject.toml
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
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
[project]
version = "0.1.12"
name = "selfcookie"
description = "Simple Python Cookiecutter Generator"
authors = [
{name = "João Pinto", email = "lamego.pinto@gmail.com"},
]
dependencies = [
"typer>=0.9.0",
"rich>=13.5.2",
]
requires-python = ">=3.11"
readme = "README.md"
license = {text = "MIT"}
[build-system]
requires = ["pdm-backend"]
build-backend = "pdm.backend"
[tool.pdm.scripts]
# git related
push = "git push"
commit = {shell = 'git commit -a -m "{args}" && git push'}
tag = {shell = 'git tag {args} && git push --tags'}
amend = "git commit --amend"
status = "git status"
version = "python -c \"import tomllib; f=open('pyproject.toml', 'rb'); print(tomllib.load(f)['project']['version'])\""
clean = "python -c \"import shutil; shutil.rmtree('__pypackages__/3.11')\""
selfcookie = "python -m selfcookie"
test = "pytest tests --cov=selfcookie --cov-report=term-missing"
# linting
lint = "pre-commit run --all-files"
# release
build = "pdm build"
release = {composite = ["pdm install", "build", "test", "lint"]}
# docs generation
docs = {shell = "cd docs && mkdocs serve", help = "Start the dev server for doc preview"}
# Dependencies below MUST be managed using:
# pdm add -dG group_name package_name, eg:
# pdm add -dG test pytest
[tool.pdm.dev-dependencies]
test = [
"pdm[pytest]",
"pytest-cov>=4.1.0",
"pytest>=7.4.0",
]
lint = [
"pre-commit>=3.3.3",
"mypy>=1.4.1",
]
release = [
"pytest>=7.4.0",
]
docs = [
"mkdocs>=1.5.2",
"pymdown-extensions>=10.1",
"mkdocs-material>=9.1.21",
]
[tool.black]
line-length = 120
[tool.isort]
profile = "black"
[tool.coverage.run]
omit = [
"selfcookie/__main__.py",
]
[tool.mypy]
disallow_untyped_defs = true
ignore_missing_imports = true