Skip to content

Commit 814ff0e

Browse files
authored
fix(github-release): correct IS_LATEST variable usage in upload condi… (#2538)
fix(github-release): correct IS_LATEST variable usage in upload condition (#2537)
1 parent 8e1992d commit 814ff0e

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

.github/workflows/github-release.yml

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,10 +30,13 @@ jobs:
3030
uses: gradle/[email protected]
3131

3232
- name: Build TarGz
33+
id: build-targz
3334
run: |
3435
./gradlew -Pprefix=automq-${{ github.ref_name }}_ --build-cache --refresh-dependencies clean releaseTarGz
3536
mkdir -p core/build/distributions/latest
3637
LATEST_TAG=$(git tag --sort=-v:refname | grep -E '^[0-9]+\.[0-9]+\.[0-9]+$' | head -n 1)
38+
echo "LATEST_TAG=$LATEST_TAG"
39+
IS_LATEST="false"
3740
if [ "$LATEST_TAG" == "${{ github.ref_name }}" ]; then
3841
IS_LATEST=true
3942
fi
@@ -52,7 +55,7 @@ jobs:
5255
5356
- uses: tvrcgo/oss-action@master
5457
name: upload-latest
55-
if: ${{ github.repository_owner == 'AutoMQ' && env.IS_LATEST == 'true' }}
58+
if: ${{ github.repository_owner == 'AutoMQ' && steps.build-targz.outputs.IS_LATEST == 'true' }}
5659
with:
5760
bucket: ${{ secrets.UPLOAD_BUCKET }}
5861
key-id: ${{ secrets.UPLOAD_BUCKET_AK }}

0 commit comments

Comments
 (0)