From 727a08ee99f8bbd96c161c9174aaf9c8bbfb38b1 Mon Sep 17 00:00:00 2001 From: Konstantin Selyunin Date: Tue, 26 Nov 2024 19:16:58 +0100 Subject: [PATCH] :wrench: dynamic versioning [#4] Add dynamic versioning based on tags. --- .github/workflows/release-and-publish-to-pypi.yml | 1 + pyproject.toml | 9 ++++++--- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/.github/workflows/release-and-publish-to-pypi.yml b/.github/workflows/release-and-publish-to-pypi.yml index 248b197..1dad995 100644 --- a/.github/workflows/release-and-publish-to-pypi.yml +++ b/.github/workflows/release-and-publish-to-pypi.yml @@ -20,6 +20,7 @@ jobs: run: | python -m pip install --upgrade pip poetry poetry install + poetry self add "poetry-dynamic-versioning[plugin]" - name: Build a binary wheel and a source tarball run: poetry build diff --git a/pyproject.toml b/pyproject.toml index 3aac060..610dadc 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,10 +1,10 @@ [build-system] -requires = ["poetry-core>=1.0.0"] -build-backend = "poetry.core.masonry.api" +requires = ["poetry-core>=1.0.0", "poetry-dynamic-versioning>=1.0.0,<2.0.0"] +build-backend = "poetry_dynamic_versioning.backend" [tool.poetry] name = "umrx-app-v3" -version = "0.0.1" +version = "0.0.0" description = "Python COINES firmware communication" authors = [ "Konstantin Selyunin ", @@ -36,6 +36,9 @@ safety = ">=2.3.4,!=2.3.5" typeguard = ">=3.0.2" unittest-parametrize = "^1.4.0" +[tool.poetry-dynamic-versioning] +enable = true + [tool.coverage.report] fail_under = 50