-
Notifications
You must be signed in to change notification settings - Fork 2
/
pyproject.toml
87 lines (79 loc) · 2.53 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
[tool.poetry]
name = "uciparse"
version = "0.0.0" # published version is managed using Git tags (see below)
description = "Parse and emit OpenWRT uci-format files"
authors = ["Kenneth J. Pronovici <pronovic@ieee.org>"]
license = "Apache-2.0"
readme = "PyPI.md"
homepage = "https://pypi.org/project/uciparse/"
repository = "https://github.com/pronovic/uci-parse"
include = [
{ path = 'Changelog', format = 'sdist' },
{ path = 'NOTICE', format = 'sdist' },
{ path = 'LICENSE', format = 'sdist' },
{ path = 'README.md', format = 'sdist' },
{ path = 'docs', format = 'sdist' },
{ path = 'tests', format = 'sdist' },
{ path = 'scripts', format = 'sdist' },
]
packages = [ { include = "uciparse", from = "src" } ]
classifiers=[
"Programming Language :: Python :: 3",
"License :: OSI Approved :: Apache Software License",
"Operating System :: OS Independent",
"Environment :: Console",
"Intended Audience :: System Administrators",
"Natural Language :: English",
"Topic :: System :: Systems Administration",
]
# Published version is managed using Git tags
# We get either the tag (like "0.24.1") or a snapshot-type version (like "0.24.1+3.e8319c4")
# If the plugin is not installed, then the version is always "0.0.0", taken from above
[tool.poetry-dynamic-versioning]
enable = true
pattern = '^[vV](?P<base>\d+\.\d+\.\d+)' # this extracts the version from our vX.Y.Z tag format
format-jinja = "{% if distance == 0 and not dirty %}{{ base }}{% else %}{{ base }}+{{ distance }}.{{ commit }}{% endif %}"
[tool.poetry.scripts]
uciparse = "uciparse.cli:parse"
ucidiff = "uciparse.cli:diff"
[tool.poetry.dependencies]
python = ">=3.10,<4"
importlib-metadata = { version="^8.5.0", optional=true }
sphinx = { version="^8.1.3", optional=true }
sphinx-autoapi = { version="^3.0.0", optional=true }
[tool.poetry.extras]
docs = [ "importlib-metadata", "sphinx", "sphinx-autoapi" ]
[tool.poetry.group.dev.dependencies]
pytest = "^8.0.2"
pytest-testdox = "^3.1.0"
coverage = "^7.4.4"
pylint = "^3.1.0"
pre-commit = "^4.0.1"
black = "^24.2.0"
mypy = "^1.6.0"
isort = "^5.12.0"
colorama = "~0, >=0.4.6"
[tool.black]
line-length = 132
target-version = [ 'py310', 'py311', 'py312', 'py313' ]
include = '(src\/scripts\/.*$|\.pyi?$)'
exclude = '''
/(
\.git
| __pycache__
| \.tox
| \.venv
| \.poetry
| build
| dist
| docs
| notes
)/
'''
[tool.isort]
profile = "black"
line_length = 132
skip_glob = [ "docs", "notes" ]
[build-system]
requires = ["poetry-core>=1.0.0", "poetry-dynamic-versioning"]
build-backend = "poetry_dynamic_versioning.backend"