From 14914d2fe8652ca5ecd6c010374b2a930164cdcf Mon Sep 17 00:00:00 2001 From: Yannic Bonenberger Date: Thu, 31 Oct 2024 00:19:51 +0100 Subject: [PATCH] fix --- .github/workflows/main.yml | 18 ++++++++++++++++-- 1 file changed, 16 insertions(+), 2 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 600fd0c..60dca49 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -55,8 +55,13 @@ jobs: # 3. Push release tag. git tag "${VERSION}" "HEAD" git push origin "${VERSION}" - + + # 4. Create release tarball + git archive -o "${RUNNER_TEMP}/archive.tar.gz" "${VERSION}" + echo "tarball-path=${RUNNER_TEMP}/archive.tar.gz" >> "${GITHUB_OUTPUT}" + - name: Create GitHub Release + id: "create-release" uses: actions/create-release@v1 with: tag_name: ${{ steps.tag.outputs.version }} @@ -66,7 +71,16 @@ jobs: To use this module, please add the following to `MODULE.bazel`: - ``` + ```starlark bazel_dep(name = "engflowapis", version = "${{ steps.tag.outputs.version }}") ``` prerelease: true + + - name: Upload Tarball + id: upload-release-asset + uses: actions/upload-release-asset@v1 + with: + upload_url: ${{ steps.create-release.outputs.upload_url }} + asset_path: ${{ steps.create-release.outputs.tarball-path }} + asset_name: engflowapis-${{ steps.tag.outputs.version }}.tar.gz + asset_content_type: "application/gzip"