This is an automated email from the ASF dual-hosted git repository.

jdaugherty pushed a commit to branch 7.0.x
in repository https://gitbox.apache.org/repos/asf/grails-core.git


The following commit(s) were added to refs/heads/7.0.x by this push:
     new da5e7650a2 [skip ci] simplify asset deletion
da5e7650a2 is described below

commit da5e7650a235fab879fd3e2a5a0cf14e43c82f56
Author: James Daugherty <[email protected]>
AuthorDate: Sun Jun 1 03:06:20 2025 -0400

    [skip ci] simplify asset deletion
---
 .github/workflows/release-source-distribution.yml | 24 +++--------------------
 1 file changed, 3 insertions(+), 21 deletions(-)

diff --git a/.github/workflows/release-source-distribution.yml 
b/.github/workflows/release-source-distribution.yml
index 8bbd1d99ba..8950ccf422 100644
--- a/.github/workflows/release-source-distribution.yml
+++ b/.github/workflows/release-source-distribution.yml
@@ -112,34 +112,16 @@ jobs:
           GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
         run: |
           set -e
-          asset_id=$(gh release view ${{ github.event.inputs.release_tag }} 
--json assets --repo ${{ github.repository }} --jq '.assets[] | select(.name == 
"CHECKSUMS.txt") | .id')
-          echo "Removing CHECKSUMS.txt asset with ID: $asset_id"
-          gh api \
-            --method DELETE \
-            -H "Accept: application/vnd.github+json" \
-            -H "X-GitHub-Api-Version: 2022-11-28" \
-            /repos/${{ github.repository }}/releases/assets/$asset_id
+          gh release delete-asset ${{ github.event.inputs.release_tag }} 
CHECKSUMS.txt --yes
       - name: "Remove BUILD_DATE.txt asset from release"
         env:
           GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
         run: |
           set -e
-          asset_id=$(gh release view ${{ github.event.inputs.release_tag }} 
--json assets --repo ${{ github.repository }} --jq '.assets[] | select(.name == 
"BUILD_DATE.txt") | .id')
-          echo "Removing BUILD_DATE.txt asset with ID: $asset_id"
-          gh api \
-            --method DELETE \
-            -H "Accept: application/vnd.github+json" \
-            -H "X-GitHub-Api-Version: 2022-11-28" \
-            /repos/${{ github.repository }}/releases/assets/$asset_id
+          gh release delete-asset ${{ github.event.inputs.release_tag }} 
BUILD_DATE.txt --yes
       - name: "Remove PUBLISHED_ARTIFACTS.txt asset from release"
         env:
           GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
         run: |
           set -e
-          asset_id=$(gh release view ${{ github.event.inputs.release_tag }} 
--json assets --repo ${{ github.repository }} --jq '.assets[] | select(.name == 
"PUBLISHED_ARTIFACTS.txt") | .id')
-          echo "Removing PUBLISHED_ARTIFACTS.txt asset with ID: $asset_id"
-          gh api \
-            --method DELETE \
-            -H "Accept: application/vnd.github+json" \
-            -H "X-GitHub-Api-Version: 2022-11-28" \
-            /repos/${{ github.repository }}/releases/assets/$asset_id
+          gh release delete-asset ${{ github.event.inputs.release_tag }} 
PUBLISHED_ARTIFACTS.txt --yes

Reply via email to