diff --git a/osmanthus/__init__.py b/osmanthus/__init__.py index e69de29..b74e39f 100644 --- a/osmanthus/__init__.py +++ b/osmanthus/__init__.py @@ -0,0 +1,5 @@ +from __future__ import annotations + +from importlib.metadata import version + +__version__ = version("osmanthus") diff --git a/pyproject.toml b/pyproject.toml index 4c64ac6..f0ecebe 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,5 +1,5 @@ [build-system] -requires = ["setuptools"] +requires = ["setuptools", "setuptools_scm"] build-backend = "setuptools.build_meta" [tool.setuptools.package-data] @@ -7,7 +7,7 @@ osmanthus = ["performance.bin"] [project] name = "osmanthus" -version = "0.1.2" +dynamic = ["version"] description = "An algorithmic chess engine, written in Python." authors = [{name = "Ian Breckenridge"}] readme = "README.md" @@ -35,3 +35,5 @@ osmanthus-cli = "osmanthus.cli:main" Repository = "https://github.com/i13e/osmanthus" Documentation = "https://github.com/i13e/osmanthus/wiki" Issues = "https://github.com/i13e/osmanthus/issues" + +[tool.setuptools_scm]