Skip to content

Commit fe719d2

Browse files
committed
Add setuptools_scm for dynamic versioning and update dependencies in pyproject.toml
1 parent 02b123a commit fe719d2

1 file changed

Lines changed: 14 additions & 1 deletion

File tree

pyproject.toml

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
11
[build-system]
2-
requires = ["scikit-build-core>=0.9", "pybind11>=2.11", "numpy"]
2+
requires = [
3+
"scikit-build-core>=0.9",
4+
"pybind11>=2.11",
5+
"numpy",
6+
"setuptools_scm[toml]>=8",
7+
]
38
build-backend = "scikit_build_core.build"
49

510
[project]
@@ -26,6 +31,14 @@ classifiers = [
2631
Homepage = "https://github.com/skilledwolf/cpp_hf"
2732
Issues = "https://github.com/skilledwolf/cpp_hf/issues"
2833

34+
# Provide version dynamically from git tags via setuptools_scm
35+
[tool.setuptools_scm]
36+
fallback_version = "0.0.0"
37+
tag_regex = "^(?:v)?(?P<version>\d+\.\d+\.\d+)$"
38+
39+
[tool.scikit-build.metadata]
40+
version = { provider = "scikit_build_core.metadata.setuptools_scm" }
41+
2942
#[tool.scikit-build]
3043
# No pure-Python packages shipped; wheel only contains the extension module
3144

0 commit comments

Comments
 (0)