Skip to content

Commit

Permalink
[tool.setuptools_scm]
Browse files Browse the repository at this point in the history
  • Loading branch information
ruguevara committed Apr 27, 2024
1 parent dffb460 commit a98c913
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 10 deletions.
5 changes: 5 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -25,3 +25,8 @@ Issues = "https://github.com/ruguevara/pyayay/issues"
[build-system]
requires = ["setuptools>=42", "wheel", "setuptools_scm", "pybind11"]
build-backend = "setuptools.build_meta"

[tool.setuptools_scm]
write_to = "version.txt"
version_scheme = "post-release"
local_scheme = "no-local-version"
10 changes: 0 additions & 10 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,6 @@
),
]

def no_dev_version(version):
if version.exact and not version.distance:
return ""
else:
return version.format_choice("+{node}", "+{node}.dirty")

setup(
name="pyayay",
author="Ruslan Grohovecki",
Expand All @@ -28,9 +22,5 @@ def no_dev_version(version):
cmdclass={"build_ext": build_ext},
zip_safe=False,
python_requires=">=3.8",
use_scm_version={
"local_scheme": no_dev_version,
"write_to": "version.txt",
},
setup_requires=["setuptools_scm"],
)

0 comments on commit a98c913

Please sign in to comment.