Skip to content

Commit a990bb2

Browse files
authored
Merge pull request #16 from jurgenwigg/dynamic-versioning
Dynamically generated version.
2 parents 3ea8562 + 2515519 commit a990bb2

3 files changed

Lines changed: 5 additions & 7 deletions

File tree

pyproject.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
[build-system]
2-
requires = ["hatchling"]
2+
requires = ["hatchling", "hatch-vcs"]
33
build-backend = "hatchling.build"
44

55
[project]
@@ -37,7 +37,7 @@ Issues = "https://github.com/nocomplexity/codeaudit/issues"
3737
Source = "https://github.com/nocomplexity/codeaudit"
3838

3939
[tool.hatch.version]
40-
path = "src/codeaudit/__about__.py"
40+
source = "vcs"
4141

4242

4343
[tool.hatch.build.targets.wheel]

src/codeaudit/__about__.py

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

src/codeaudit/__init__.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
# SPDX-FileCopyrightText: 2025-present Maikel Mardjan - https://nocomplexity.com/
22
#
33
# SPDX-License-Identifier: GPL-3.0-or-later
4-
from .__about__ import __version__
4+
from importlib.metadata import version
5+
6+
__version__ = version("codeaudit")

0 commit comments

Comments
 (0)