From e6d07367e09ff58f623313b5af50ad9ffd16b2a7 Mon Sep 17 00:00:00 2001 From: Gnarwhal Date: Thu, 1 Aug 2024 06:16:09 +0000 Subject: [PATCH] Add version file information (because setuptools_scm is mean and won't work with release tarballs ;-;) --- .gitignore | 3 --- pyproject.toml | 7 ++----- src/sshare/_version.py | 14 ++++++++++++++ 3 files changed, 16 insertions(+), 8 deletions(-) create mode 100644 src/sshare/_version.py diff --git a/.gitignore b/.gitignore index 678f87e..489bdd0 100644 --- a/.gitignore +++ b/.gitignore @@ -159,6 +159,3 @@ cython_debug/ # and can be added to the global gitignore or merged into this file. For a more nuclear # option (not recommended) you can uncomment the following to ignore the entire idea folder. #.idea/ - -# Version file -_version.py diff --git a/pyproject.toml b/pyproject.toml index 029509e..cdef342 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,10 +1,10 @@ [build-system] -requires = ["setuptools", "setuptools_scm"] +requires = ["setuptools"] build-backend = "setuptools.build_meta" [project] name = "sshare" -dynamic = ["version"] +version = "1.0.0" authors = [ { name = "Gnarwhal", email = "git.aspect893@passmail.net" }, ] @@ -28,6 +28,3 @@ Issues = "https://forge.monodon.me/Gnarwhal/sshare/issues" [project.scripts] sshare = "sshare.cli:main" - -[tool.setuptools_scm] -version_file = "src/sshare/_version.py" diff --git a/src/sshare/_version.py b/src/sshare/_version.py new file mode 100644 index 0000000..e59579f --- /dev/null +++ b/src/sshare/_version.py @@ -0,0 +1,14 @@ +TYPE_CHECKING = False +if TYPE_CHECKING: + from typing import Tuple, Union + VERSION_TUPLE = Tuple[Union[int, str], ...] +else: + VERSION_TUPLE = object + +version: str +__version__: str +__version_tuple__: VERSION_TUPLE +version_tuple: VERSION_TUPLE + +__version__ = version = '1.0.0' +__version_tuple__ = version_tuple = (1, 0, 0)