Skip to content

Commit 0bd54dc

Browse files
committed
Migrated setuptools metadata to pyproject.toml
1 parent 6c3b4fe commit 0bd54dc

File tree

2 files changed

+45
-22
lines changed

2 files changed

+45
-22
lines changed

pyproject.toml

+45-6
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,50 @@
11
[build-system]
22

33
requires = [
4-
"setuptools >= 40.9.0",
5-
"wheel",
4+
"setuptools >= 40.9.0",
5+
"wheel",
66
]
77
build-backend = "setuptools.build_meta"
88

9+
[project]
10+
name = "bump-my-version"
11+
description = "Version bump your Python project"
12+
authors = [
13+
{ name = "Corey Oordt", email = "[email protected]" }
14+
]
15+
classifiers = [
16+
"Development Status :: 5 - Production/Stable",
17+
"Environment :: Console",
18+
"Intended Audience :: Developers",
19+
"License :: OSI Approved :: MIT License",
20+
"Operating System :: OS Independent",
21+
"Programming Language :: Python",
22+
"Programming Language :: Python :: 3 :: Only",
23+
"Programming Language :: Python :: 3.7",
24+
"Programming Language :: Python :: 3.8",
25+
"Programming Language :: Python :: 3.9",
26+
"Programming Language :: Python :: 3.10",
27+
"Programming Language :: Python :: 3.11",
28+
"Programming Language :: Python :: 3.12",
29+
"Programming Language :: Python :: Implementation :: PyPy",
30+
"Topic :: Software Development :: Build Tools",
31+
"Topic :: Software Development :: Version Control",
32+
"Topic :: System :: Software Distribution",
33+
]
34+
readme = "README.md"
35+
requires-python = ">=3.7"
36+
license = { file = "LICENSE" }
37+
keywords = ["bumpversion", "version", "release"]
38+
dynamic = ["version"]
39+
40+
[project.urls]
41+
homepage = "https://github.com/callowayproject/bump-my-version"
42+
repository = "https://github.com/callowayproject/bump-my-version.git"
43+
documentation = "https://callowayproject.github.io/bump-my-version/"
44+
45+
[tool.setuptools.dynamic]
46+
version = {attr = "bumpversion.__version__"}
47+
948
[tool.coverage.run]
1049
branch = true
1150
omit = ["**/test_*.py", "**/__main__.py", "**/aliases.py"]
@@ -73,7 +112,7 @@ line-length = 119
73112
[tool.ruff]
74113
# Enable pycodestyle (`E`) and Pyflakes (`F`) codes by default.
75114
# "UP" "TRY" "PLR"
76-
select = ["E", "W", "F", "I", "N", "B", "BLE", "C", "D", "E", "F", "I", "N", "S", "T", "W", "RUF", "NPY", "PD", "PGH", "ANN", "C90", "PLC", "PLE", "PLW", "TCH"]
115+
select = ["E", "W", "F", "I", "N", "B", "BLE", "C", "D", "E", "F", "I", "N", "S", "T", "W", "RUF", "NPY", "PD", "PGH", "ANN", "C90", "PLC", "PLE", "PLW", "TCH"]
77116
ignore = [
78117
"ANN002", "ANN003", "ANN101", "ANN102", "ANN204", "ANN401",
79118
"S101", "S104",
@@ -82,7 +121,7 @@ ignore = [
82121
]
83122

84123
# Allow autofix for all enabled rules (when `--fix`) is provided.
85-
fixable = ["E", "W", "F", "I", "N", "B", "BLE", "C", "D", "E", "F", "I", "N", "S", "T", "W", "RUF", "NPY", "PD", "PGH", "ANN", "C90", "PL", "PLC", "PLE", "PLW", "TCH"]
124+
fixable = ["E", "W", "F", "I", "N", "B", "BLE", "C", "D", "E", "F", "I", "N", "S", "T", "W", "RUF", "NPY", "PD", "PGH", "ANN", "C90", "PL", "PLC", "PLE", "PLW", "TCH"]
86125
unfixable = []
87126

88127
# Exclude a variety of commonly ignored directories.
@@ -118,7 +157,7 @@ dummy-variable-rgx = "^(_+|(_+[a-zA-Z0-9_]*[a-zA-Z0-9]+?))$"
118157
typing-modules = ["typing", "types", "typing_extensions", "mypy", "mypy_extensions"]
119158

120159
[tool.ruff.per-file-ignores]
121-
"tests/*"=["S101", "PLR0913", "PLR0915", "PGH003", "ANN001", "ANN202", "ANN201", "PLR0912", "TRY301", "PLW0603", "PLR2004", "ANN101", "S106", "TRY201", "ANN003", "ANN002", "S105", "TRY003"]
160+
"tests/*" = ["S101", "PLR0913", "PLR0915", "PGH003", "ANN001", "ANN202", "ANN201", "PLR0912", "TRY301", "PLW0603", "PLR2004", "ANN101", "S106", "TRY201", "ANN003", "ANN002", "S105", "TRY003"]
122161

123162
[tool.ruff.mccabe]
124163
# Unlike Flake8, default to a complexity level of 10.
@@ -138,7 +177,7 @@ tag = true
138177
tag_name = "{new_version}"
139178
allow_dirty = true
140179
parse = "(?P<major>\\d+)\\.(?P<minor>\\d+)\\.(?P<patch>\\d+)(\\.dev(?P<dev>\\d+))?"
141-
serialize =[
180+
serialize = [
142181
"{major}.{minor}.{patch}.dev{dev}",
143182
"{major}.{minor}.{patch}"
144183
]

setup.cfg

-16
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,3 @@
1-
[metadata]
2-
name = bump-my-version
3-
version = attr:bumpversion.__version__
4-
description = Version bump your Python project
5-
url = https://github.com/callowayproject/bump-my-version
6-
author = Corey Oordt
7-
author_email = [email protected]
8-
classifiers =
9-
Development Status :: 3 - Alpha
10-
Intended Audience :: Developers
11-
Natural Language :: English
12-
Programming Language :: Python :: 3.9
13-
long_description = file:README.md
14-
long_description_content_type = text/markdown
15-
keywords = bumpversion
16-
171
[options]
182
zip_safe = False
193
include_package_data = True

0 commit comments

Comments
 (0)