gisaf-backend/src/gisaf/__init__.py
2025-06-28 04:42:10 +02:00

11 lines
410 B
Python

import importlib.metadata
try:
from dunamai import Version, Style
__version__ = Version.from_git().serialize(style=Style.SemVer, dirty=True)
except (ImportError, RuntimeError):
# __name__ could be used if the package name is the same
# as the directory - not the case here
# __version__ = importlib.metadata.version(__name__)
__version__ = importlib.metadata.version("gisaf-backend")