Skip to content

Commit ced7dad

Browse files
committed
chore: move to setuptools_scm
Signed-off-by: Henry Schreiner <[email protected]>
1 parent 936cf6f commit ced7dad

File tree

7 files changed

+15
-2361
lines changed

7 files changed

+15
-2361
lines changed

.git_archival.txt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
node: $Format:%H$
2+
node-date: $Format:%cI$
3+
describe-name: $Format:%(describe:tags=true,match=*[0-9]*)$
4+
ref-names: $Format:%D$

.gitattributes

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
src/ninja/_version.py export-subst
1+
.git_archival.txt export-subst

.gitignore

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,3 +59,9 @@ docs/_build
5959
.idea/*
6060
*.swp
6161
*~
62+
63+
# Output from cibuildwheel
64+
/wheelhouse
65+
66+
# Version
67+
_version.py

pyproject.toml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,14 @@
11
[build-system]
22
requires = [
33
"setuptools >=42",
4+
"setuptools-scm[toml]",
45
"scikit-build",
56
]
67
build-backend = "setuptools.build_meta"
78

9+
[tool.setuptools_scm]
10+
write_to = "src/ninja/_version.py"
11+
812
[tool.cibuildwheel]
913
build = "cp39-*"
1014
build-verbosity = 1

setup.py

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,6 @@
1313
# is already installed (c.f. https://github.com/scikit-build/cmake-python-distributions/issues/171)
1414
sys.path.insert(0, os.path.dirname(os.path.abspath(__file__)))
1515

16-
import versioneer # noqa: E402
17-
1816
with open('README.rst', 'r') as fp:
1917
readme = fp.read()
2018

@@ -34,9 +32,6 @@ def parse_requirements(filename):
3432
setup(
3533
name='ninja',
3634

37-
version=versioneer.get_version(),
38-
cmdclass=versioneer.get_cmdclass(),
39-
4035
author='Jean-Christophe Fillion-Robin',
4136
author_email='[email protected]',
4237

0 commit comments

Comments
 (0)