@@ -3,7 +3,7 @@ name: Release
33on :
44 # 新发布触发
55 release :
6- types : [published]
6+ types : [ published ]
77
88 # 手动触发
99 workflow_dispatch :
2828 strategy :
2929 fail-fast : false
3030 matrix :
31- platform : [macos-latest, windows-latest]
31+ platform : [ macos-latest, windows-latest ]
3232 include :
3333 - platform : macos-latest
3434 os : macos
@@ -79,11 +79,34 @@ jobs:
7979 - name : Build application
8080 run : pnpm tauri build --target ${{ matrix.target }}
8181
82- - name : Upload build artifacts
82+ - name : List build output (debug)
83+ run : |
84+ echo "=== Build output structure ==="
85+ find src-tauri/target -name "*.dmg" -o -name "*.app" -o -name "*.msi" -o -name "*.exe" | grep -E "\.(dmg|app|msi)$|CodeForge.*\.exe$" | head -20
86+ echo "=== Target directories ==="
87+ ls -la src-tauri/target/ || echo "Target directory not found"
88+ echo "=== Bundle directories ==="
89+ find src-tauri/target -name "bundle" -type d | head -10
90+ shell : bash
91+
92+ - name : Upload build artifacts (macOS)
93+ if : matrix.platform == 'macos-latest'
94+ uses : actions/upload-artifact@v4
95+ with :
96+ name : release-${{ matrix.os }}
97+ path : |
98+ src-tauri/target/universal-apple-darwin/release/bundle/dmg/*.dmg
99+ src-tauri/target/universal-apple-darwin/release/bundle/macos/*.app
100+ retention-days : 30
101+
102+ - name : Upload build artifacts (Windows)
103+ if : matrix.platform == 'windows-latest'
83104 uses : actions/upload-artifact@v4
84105 with :
85106 name : release-${{ matrix.os }}
86- path : src-tauri/target/release/bundle/
107+ path : |
108+ src-tauri/target/x86_64-pc-windows-msvc/release/bundle/msi/*.msi
109+ src-tauri/target/x86_64-pc-windows-msvc/release/bundle/nsis/*.exe
87110 retention-days : 30
88111
89112 # 创建或更新 GitHub Release
@@ -141,4 +164,4 @@ jobs:
141164 tag_name : ${{ github.event.release.tag_name }}
142165 files : release-assets/*
143166 env :
144- GH_TOKEN : ${{ secrets.GH_TOKEN }}
167+ GH_TOKEN : ${{ secrets.GH_TOKEN }}
0 commit comments