From c505c30170b2691512655deed20b070a4d5f7a73 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Elijas=20Dap=C5=A1auskas?= <4084885+Elijas@users.noreply.github.com> Date: Tue, 26 Sep 2023 02:45:53 +0300 Subject: [PATCH] fix(packaging): use post-release versions for PyPI compatibility --- .github/workflows/release.yml | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 4464a28..f953d5d 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -30,13 +30,12 @@ jobs: run: poetry build - name: Publish package run: | - # Use the build number to create a local version identifier + # Use the build number to create a pre-release or post-release version identifier if [[ "${{ github.event_name }}" == "workflow_dispatch" ]]; then BUILD_NUMBER=${{ github.event.inputs.build_number }} POETRY_VERSION=$(poetry version | awk '{print $2}') - NEW_VERSION="${POETRY_VERSION}+build${BUILD_NUMBER}" + NEW_VERSION="${POETRY_VERSION}.post${BUILD_NUMBER}" poetry version "${NEW_VERSION}" fi poetry build poetry publish --username __token__ --password ${{ secrets.PUBLIC_PYPI_API_TOKEN }} - \ No newline at end of file