From d4f300d53da852c6f972659e81625ad67d93dfc9 Mon Sep 17 00:00:00 2001 From: Mohammed Naser Date: Tue, 3 Jun 2025 19:43:15 +0000 Subject: [PATCH] =?UTF-8?q?=E2=9C=A8=20chore:=20update=20version=20retriev?= =?UTF-8?q?al=20method=20and=20configure=20version=20file?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Mohammed Naser --- .gitignore | 1 + build/build-manila-image.sh | 2 +- pyproject.toml | 3 +++ 3 files changed, 5 insertions(+), 1 deletion(-) diff --git a/.gitignore b/.gitignore index 8aca44a2..3c967aed 100644 --- a/.gitignore +++ b/.gitignore @@ -26,6 +26,7 @@ collections/ *.egg-info CHANGELOG.rst target +atmosphere/_version.py ## Editors .idea diff --git a/build/build-manila-image.sh b/build/build-manila-image.sh index 2ad7ece9..cf67566b 100755 --- a/build/build-manila-image.sh +++ b/build/build-manila-image.sh @@ -3,7 +3,7 @@ set -xe -ATMOSPHERE_VERSION=$(pbr info -s atmosphere) +ATMOSPHERE_VERSION=$(python3 -c "from atmosphere._version import __version__; print(__version__)") # Create work directory TMPDIR=$(mktemp -d) diff --git a/pyproject.toml b/pyproject.toml index 281b894b..163dc7a1 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -48,3 +48,6 @@ issues = "https://github.com/vexxhost/atmosphere/issues" [tool.hatch.version] source = "vcs" + +[tool.hatch.build.hooks.vcs] +version-file = "atmosphere/_version.py"