@@ -49,28 +49,17 @@ jobs:
4949 while read -r hash message; do
5050 changelog="${changelog}* [${message}](${repo_url}/commit/${hash})"$'\n'
5151 done < <(git log $range --pretty=format:"%H %s")
52- echo "changelog<<EOF" >> $GITHUB_ENV
53- echo "$changelog" >> $GITHUB_ENV
54- echo "EOF" >> $GITHUB_ENV
52+ echo "changelog<<EOF" >> $GITHUB_OUTPUT
53+ echo "$changelog" >> $GITHUB_OUTPUT
54+ echo "EOF" >> $GITHUB_OUTPUT
5555
56- - name : Create Release
57- id : create_release
58- uses : actions/create-release@v1
56+ - name : Create Release and Upload Asset (gh CLI)
5957 env :
6058 GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
61- with :
62- tag_name : apache-iceberg-monitoring-${{ github.sha }}
63- release_name : apache-iceberg-monitoring-${{ steps.zip.outputs.commit_hash }}
64- body : ${{ env.changelog }}
65- draft : false
66- prerelease : false
67-
68- - name : Upload Release Asset
69- uses : actions/upload-release-asset@v1
70- env :
71- GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
72- with :
73- upload_url : ${{ steps.create_release.outputs.upload_url }}
74- asset_path : ./${{ steps.zip.outputs.zip_name }}
75- asset_name : ${{ steps.zip.outputs.zip_name }}
76- asset_content_type : application/zip
59+ run : |
60+ # Create the release
61+ gh release create "apache-iceberg-monitoring-${{ steps.zip.outputs.commit_hash }}" \
62+ --title "apache-iceberg-monitoring-${{ steps.zip.outputs.commit_hash }}" \
63+ --notes "${{ steps.changelog.outputs.changelog }}" \
64+ --target ${{ github.sha }} \
65+ ./${{ steps.zip.outputs.zip_name }}
0 commit comments