diff --git a/changelog/719.trivial.rst b/changelog/719.trivial.rst new file mode 100644 index 00000000..8fdb3b65 --- /dev/null +++ b/changelog/719.trivial.rst @@ -0,0 +1 @@ +Use up-to-date ``setup.cfg``/``pyproject.toml`` packaging setup. diff --git a/pyproject.toml b/pyproject.toml index 94b1be61..72a7f7d7 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,3 +1,15 @@ +[build-system] +requires = [ + # sync with setup.py until we discard non-pep-517/518 + "setuptools>=45.0", + "setuptools-scm[toml]>=6.2.3", + "wheel", +] +build-backend = "setuptools.build_meta" + +[tool.setuptools_scm] +write_to = "src/xdist/_version.py" + [tool.towncrier] package = "xdist" filename = "CHANGELOG.rst" diff --git a/setup.cfg b/setup.cfg index e442e9c8..ad5a0eb9 100644 --- a/setup.cfg +++ b/setup.cfg @@ -40,7 +40,7 @@ install_requires = execnet>=1.1 pytest>=6.0.0 pytest-forked -setup_requires = setuptools_scm +setup_requires = setuptools_scm>=6.0 [options.packages.find] where = src diff --git a/setup.py b/setup.py index 28aefd7b..7f1a1763 100644 --- a/setup.py +++ b/setup.py @@ -1,6 +1,4 @@ from setuptools import setup if __name__ == "__main__": - setup( - use_scm_version={"write_to": "src/xdist/_version.py"}, - ) + setup()