-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathpyproject.toml
128 lines (102 loc) · 2.47 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
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
[project]
name = "YubiOTP"
version = "1.0.0"
description = "A library for verifying YubiKey OTP tokens, both locally and through a Yubico web service."
readme = "README.rst"
requires-python = ">=3.7"
license = "Unlicense"
authors = [
{ name = "Peter Sagerson", email = "psagers@ignorare.net" },
]
classifiers = [
"Development Status :: 5 - Production/Stable",
"Intended Audience :: Developers",
"License :: OSI Approved :: BSD License",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3 :: Only",
"Topic :: Security",
"Topic :: Software Development :: Libraries :: Python Modules",
]
dependencies = [
"pycryptodome",
]
[project.urls]
Homepage = "https://github.com/django-otp/yubiotp"
Documentation = "https://yubiotp.readthedocs.io/"
[project.scripts]
yubiclient = "yubiotp.cli.yubiclient:main"
yubikey = "yubiotp.cli.yubikey:main"
#
# Development
#
[tool.hatch.envs.default]
dependencies = [
"black ~= 24.8.0",
"bumpversion ~= 0.6.0",
"coverage ~= 7.6.1",
"flake8 ~= 7.1.1",
"isort ~= 5.13.1",
]
[tool.hatch.envs.default.scripts]
lint = [
"flake8 yubiotp",
"isort --check yubiotp",
"black --check yubiotp",
]
fix = [
"isort yubiotp",
"black yubiotp",
]
test = "python -s -m unittest {args}"
check = ["lint", "test"]
warn = "python -Wd -s -m unittest {args}"
cov = [
"coverage run -m unittest {args}",
"coverage report",
]
[tool.hatch.envs.test.scripts]
run = "test"
[tool.hatch.envs.test.overrides]
matrix.mode.scripts = [
{ key = "run", value = "lint", if = ["lint"] },
{ key = "run", value = "cov", if = ["coverage"] },
]
[[tool.hatch.envs.test.matrix]]
mode = ["lint"]
# WARNING: When you update the Python versions, make sure to update
# .github/workflows/* as well.
[[tool.hatch.envs.test.matrix]]
python = ["3.8", "3.9", "3.10", "3.11", "3.12"]
[[tool.hatch.envs.test.matrix]]
mode = ["coverage"]
[tool.hatch.envs.docs]
template = "docs"
dependencies = [
"sphinx"
]
[tool.hatch.envs.docs.scripts]
make = "command make -C docs {args:html}"
open = "command xdg-open docs/build/html/index.html"
#
# Build
#
[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"
[tool.hatch.build.targets.wheel]
packages = ["yubiotp"]
[tool.hatch.build.targets.sdist]
include = [
"/bin",
"/docs",
"/yubiotp",
"/CHANGES.rst",
]
#
# Other tools
#
[tool.isort]
profile = "black"
force_sort_within_sections = true
[tool.black]
skip-string-normalization = true