From ab85c0f5a9b20d6ddc04dbdeb7f2481a84ef870b Mon Sep 17 00:00:00 2001 From: Trenton H <797416+stumpylog@users.noreply.github.com> Date: Fri, 11 Aug 2023 01:37:38 -0700 Subject: [PATCH] Enables creation of a release and uploading the build assets to it (#1132) --- .github/workflows/build.yml | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 43c8432a..977f0ebc 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -255,6 +255,32 @@ jobs: password: ${{ secrets.TOKEN_PYPI }} # repository_url: https://test.pypi.org/legacy/ + create_release: + name: Create GitHub release + needs: [wheel_sdist_linux, test_linux, test_macos, test_windows] + runs-on: ubuntu-latest + if: github.event_name == 'push' && startsWith(github.event.ref, 'refs/tags/v') + permissions: + # Required to create a release + contents: write + steps: + - uses: actions/download-artifact@v3 + with: + name: artifact + path: dist + + - name: Create Release + id: create-release + uses: shogo82148/actions-create-release@v1 + + - name: Upload Assets + uses: shogo82148/actions-upload-release-asset@v1 + with: + upload_url: ${{ steps.create-release.outputs.upload_url }} + asset_path: | + ./dist/*.whl + ./dist/*.tar.gz + docker: name: Build Docker images needs: [wheel_sdist_linux, test_linux, test_macos, test_windows]