From a4f32b1943524fa0eed9192b358e6324fa43844a Mon Sep 17 00:00:00 2001 From: Jakob Keller <57402305+jakob-keller@users.noreply.github.com> Date: Wed, 21 Aug 2024 12:46:43 +0200 Subject: [PATCH] build distribution unconditionally and perform metadata validation in CI/CD workflow (#1164) --- .github/workflows/ci-cd.yml | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/.github/workflows/ci-cd.yml b/.github/workflows/ci-cd.yml index e5489627..c461ce37 100644 --- a/.github/workflows/ci-cd.yml +++ b/.github/workflows/ci-cd.yml @@ -72,9 +72,6 @@ jobs: needs: - test - # Run only on pushing a tag - if: github.event_name == 'push' && contains(github.ref, 'refs/tags/') - steps: - uses: actions/checkout@v4 @@ -87,6 +84,11 @@ jobs: python -m pip install build python -m build + - name: Check release distributions + run: | + python -m pip install twine + python -m twine check --strict dist/* + - name: Upload distributions uses: actions/upload-artifact@v4 with: @@ -99,6 +101,9 @@ jobs: needs: - release-build + # Run only on pushing a tag + if: github.event_name == 'push' && contains(github.ref, 'refs/tags/') + permissions: # IMPORTANT: this permission is mandatory for trusted publishing id-token: write