-
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpyproject.toml
More file actions
105 lines (91 loc) · 2.36 KB
/
pyproject.toml
File metadata and controls
105 lines (91 loc) · 2.36 KB
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
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
[build-system]
build-backend = "hatchling.build"
requires = [
"hatchling",
"hatch-vcs",
]
[project]
name = "gomi"
dynamic = ["version"]
description = 'Package to store and manage Note Types for Anki in a git repository.'
readme = "README.md"
requires-python = ">=3.12"
license = { file = "LICENSE" }
keywords = []
authors = [
{ name = "Ajatt-Tools and contributors" },
]
classifiers = [
"Programming Language :: Python",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Programming Language :: Python :: Implementation :: CPython",
"Programming Language :: Python :: Implementation :: PyPy",
]
dependencies = []
[project.urls]
Documentation = "https://github.com/Ajatt-Tools/gomi#readme"
Issues = "https://github.com/Ajatt-Tools/gomi/issues"
Source = "https://github.com/Ajatt-Tools/gomi"
[project.scripts]
gomi = "gomi.__main__:main"
[tool.hatch.version]
source = "vcs"
path = "gomi/__about__.py"
[tool.hatch.build.hooks.vcs]
version-file = "gomi/__about__.py"
[tool.hatch.envs.types]
extra-dependencies = [
"mypy>=1.0.0",
]
[tool.hatch.envs.types.scripts]
check = "mypy --install-types --non-interactive {args:src/gomi tests}"
[tool.coverage.run]
source_pkgs = ["gomi", "tests"]
branch = true
parallel = true
omit = [
"src/gomi/__about__.py",
]
[tool.coverage.paths]
gomi = ["src/gomi", "*/gomi/src/gomi"]
tests = ["tests", "*/gomi/tests"]
[tool.coverage.report]
exclude_lines = [
"no cov",
"if __name__ == .__main__.:",
"if TYPE_CHECKING:",
]
[tool.black]
line-length = 120
target-version = ['py312']
unstable = true
[tool.isort]
profile = "black"
[tool.hatch.envs.hatch-test]
# https://hatch.pypa.io/latest/config/internal/testing/
# https://hatch.pypa.io/latest/tutorials/testing/overview/
dependencies = [
"mypy>=1.0.0",
"pytest",
]
parallel = true
randomize = true
[tool.hatch.envs.hatch-static-analysis]
# https://hatch.pypa.io/latest/how-to/static-analysis/behavior/
dependencies = [
"black",
"flake8",
"isort",
"pyupgrade",
]
[tool.hatch.envs.hatch-static-analysis.scripts]
format-check = [
"black --check --diff {args:.}",
"isort --check-only --diff {args:.}",
]
format-fix = [
"pyupgrade --py313-plus gomi/*.py tests/*.py; isort gomi tests; black gomi tests; ", # run as: hatch fmt -f
]
lint-check = "flake8 --max-line-length 120 {args:.}"
lint-fix = "lint-check"