Skip to content

Commit 02bb907

Browse files
committed
delete latest before creating
1 parent 45ec109 commit 02bb907

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

.github/workflows/build.yml

+8-1
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,14 @@ jobs:
5252
msposd_x86
5353
msposd_jetson
5454
55+
- name: Delete existing latest release
56+
if: github.ref == 'refs/heads/add-jetson-action' && github.event_name == 'push'
57+
env:
58+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
59+
run: |
60+
curl -s -X DELETE -H "Authorization: token $GITHUB_TOKEN" \
61+
"https://api.github.com/repos/${{ github.repository }}/releases/tags/latest" || echo "No existing latest release"
62+
5563
- name: Upload latest
5664
if: github.ref == 'refs/heads/add-jetson-action' && github.event_name == 'push'
5765
uses: softprops/action-gh-release@v2
@@ -66,4 +74,3 @@ jobs:
6674
msposd_star6e
6775
msposd_x86
6876
msposd_jetson
69-

0 commit comments

Comments
 (0)