mirror of
https://github.com/memohai/Memoh.git
synced 2026-04-25 07:00:48 +09:00
fix(release): publish assets in single serial step
Avoid race conditions during release uploads by moving asset publication out of matrix jobs and into one dedicated job. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -82,13 +82,41 @@ jobs:
|
||||
UPX_ARGS: "-3"
|
||||
run: scripts/release.sh
|
||||
|
||||
- name: Upload release assets
|
||||
- name: Upload tar artifact
|
||||
if: matrix.goos != 'windows'
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: release-assets-${{ matrix.goos }}-${{ matrix.goarch }}
|
||||
path: dist/*.tar.gz
|
||||
if-no-files-found: error
|
||||
retention-days: 1
|
||||
|
||||
- name: Upload zip artifact
|
||||
if: matrix.goos == 'windows'
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: release-assets-${{ matrix.goos }}-${{ matrix.goarch }}
|
||||
path: dist/*.zip
|
||||
if-no-files-found: error
|
||||
retention-days: 1
|
||||
|
||||
publish-release:
|
||||
needs: build-binaries
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Download release artifacts
|
||||
uses: actions/download-artifact@v4
|
||||
with:
|
||||
pattern: release-assets-*
|
||||
path: dist
|
||||
merge-multiple: true
|
||||
|
||||
- name: Publish release assets
|
||||
uses: softprops/action-gh-release@v2
|
||||
with:
|
||||
files: |
|
||||
dist/*.tar.gz
|
||||
dist/*.zip
|
||||
files: dist/*
|
||||
tag_name: ${{ github.ref_name }}
|
||||
overwrite_files: true
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user