Skip to content

Commit a4870ef

Browse files
committed
ci(release): replace softprops/action-gh-release with gh CLI + add permissions
softprops/action-gh-release@v1 consistently fails with 403 / Too many retries on this repository. Switch to native gh release create CLI which uses the same GITHUB_TOKEN but has better error handling. Also add explicit permissions: contents: write.
1 parent 2867811 commit a4870ef

1 file changed

Lines changed: 9 additions & 5 deletions

File tree

‎.github/workflows/release.yml‎

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,9 @@ on:
88
env:
99
CARGO_TERM_COLOR: always
1010

11+
permissions:
12+
contents: write
13+
1114
jobs:
1215
build-windows:
1316
name: Build Windows Release
@@ -45,9 +48,10 @@ jobs:
4548
Compress-Archive -Path $outDir -DestinationPath "$outDir.zip" -Force
4649
Write-Host "Created $outDir.zip"
4750
- name: Upload to GitHub Release
48-
uses: softprops/action-gh-release@v1
49-
with:
50-
files: devbase-*-windows-x64.zip
51-
generate_release_notes: true
51+
shell: powershell
5252
env:
53-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
53+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
54+
run: |
55+
$version = "${{ github.ref_name }}"
56+
$archive = "devbase-$version-windows-x64.zip"
57+
gh release create $version $archive --generate-notes --repo ${{ github.repository }}

0 commit comments

Comments
 (0)