Skip to content

Commit 130dcde

Browse files
committed
Add build-system to pyproject.toml
So doesn't use legacy stuff. Fix #719.
1 parent f8a434e commit 130dcde

File tree

4 files changed

+15
-4
lines changed

4 files changed

+15
-4
lines changed

changelog/719.trivial.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Use up-to-date ``setup.cfg``/``pyproject.toml`` packaging setup.

pyproject.toml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,15 @@
1+
[build-system]
2+
requires = [
3+
# sync with setup.py until we discard non-pep-517/518
4+
"setuptools>=45.0",
5+
"setuptools-scm[toml]>=6.2.3",
6+
"wheel",
7+
]
8+
build-backend = "setuptools.build_meta"
9+
10+
[tool.setuptools_scm]
11+
write_to = "src/xdist/_version.py"
12+
113
[tool.towncrier]
214
package = "xdist"
315
filename = "CHANGELOG.rst"

setup.cfg

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ install_requires =
4040
execnet>=1.1
4141
pytest>=6.0.0
4242
pytest-forked
43-
setup_requires = setuptools_scm
43+
setup_requires = setuptools_scm>=6.0
4444

4545
[options.packages.find]
4646
where = src

setup.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,4 @@
11
from setuptools import setup
22

33
if __name__ == "__main__":
4-
setup(
5-
use_scm_version={"write_to": "src/xdist/_version.py"},
6-
)
4+
setup()

0 commit comments

Comments
 (0)