diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 77e7f4b..3bb2474 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -514,16 +514,9 @@ jobs: # This workflow has added a `git fetch --force --tags` to every job that # needs to have working tags # - upload_release: - name: Upload Release Assets + get_tagtype: + name: Get type of Tag if: startsWith(github.ref, 'refs/tags/') - needs: - - package_dpkg - - package_rpm - - binaries_windows - - binaries_macos - - binaries_macos_universal - - binaries_linux_crosscompile runs-on: ubuntu-latest steps: @@ -533,16 +526,15 @@ jobs: run: | git fetch --force --tags - - name: Get Tag Type + - name: Debug data for Get Tag Type run: | TYPE=$(git cat-file -t $GITHUB_REF) - echo "::set-output name=TAGTYPE::$TYPE" echo ========== echo REF=$GITHUB_REF echo TAGTYPE=$GITHUB_REF echo ========== - echo git cat-file $GITHUB_REF - git cat-file $GITHUB_REF + echo git cat-file $TYPE $GITHUB_REF + git cat-file $TYPE $GITHUB_REF echo ========== echo ls .git/refs/heads ls .git/refs/heads @@ -556,6 +548,35 @@ jobs: echo git for-each-ref refs/tags git for-each-ref refs/tags + + upload_release: + name: Upload Release Assets + if: startsWith(github.ref, 'refs/tags/') + needs: + - package_dpkg + - package_rpm + - binaries_windows + - binaries_macos + - binaries_macos_universal + - binaries_linux_crosscompile + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v2 + + - name: Fix Checkout + run: | + git fetch --force --tags + + - name: Get Tag Type + id: get_tagtype + run: | + TYPE=$(git cat-file -t $GITHUB_REF) + echo "::set-output name=TAGTYPE::$TYPE" + echo ========== + echo REF=$GITHUB_REF + echo TAGTYPE=$GITHUB_REF + - name: Fetch all Artifacts if: steps.get_tagtype.outputs.TAGTYPE == 'tag' uses: actions/download-artifact@v2