Skip to content

Commit 88f1e9d

Browse files
committed
use setuptools_scm
1 parent d5a12ff commit 88f1e9d

File tree

3 files changed

+6
-21
lines changed

3 files changed

+6
-21
lines changed

mpl_point_clicker/_version.py

Lines changed: 0 additions & 7 deletions
This file was deleted.

pyproject.toml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,9 @@
22
skip-string-normalization = true
33

44
[build-system]
5-
requires = ["setuptools>=42", "wheel"]
5+
requires = ["setuptools>=42", "wheel", "setuptools_scm>=6.2"]
66
build-backend = "setuptools.build_meta"
7+
8+
9+
[tool.setuptools_scm]
10+
write_to = "mpl_point_clicker/_version.py"

setup.py

Lines changed: 1 addition & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,5 @@
1-
from os import path
2-
31
from setuptools import setup
42

5-
# extract version
6-
path = path.realpath("mpl_point_clicker/_version.py")
7-
version_ns = {}
8-
with open(path, encoding="utf8") as f:
9-
exec(f.read(), {}, version_ns)
10-
version = version_ns["__version__"]
11-
12-
setup_args = dict(
13-
version=version,
14-
)
153

164
if __name__ == "__main__":
17-
setup(**setup_args)
5+
setup()

0 commit comments

Comments
 (0)