mirror of
https://wget.la/https://github.com/Wxw-Gu/WechatExplorer
synced 2026-08-18 03:57:02 +08:00
fix: 修复 release workflow - 改用 npm 安装 pnpm 和 artifacts 上传
Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
@@ -10,11 +10,7 @@ jobs:
|
|||||||
runs-on: macos-latest
|
runs-on: macos-latest
|
||||||
strategy:
|
strategy:
|
||||||
matrix:
|
matrix:
|
||||||
include:
|
platform: [x64, arm64]
|
||||||
- platform: macos-arm64
|
|
||||||
arch: arm64
|
|
||||||
- platform: macos-x64
|
|
||||||
arch: x64
|
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
@@ -27,9 +23,7 @@ jobs:
|
|||||||
cache: 'pnpm'
|
cache: 'pnpm'
|
||||||
|
|
||||||
- name: Install pnpm
|
- name: Install pnpm
|
||||||
uses: pnpm/action-setup@v4
|
run: npm install -g pnpm@9
|
||||||
with:
|
|
||||||
version: '9'
|
|
||||||
|
|
||||||
- name: Install Dependencies
|
- name: Install Dependencies
|
||||||
run: pnpm install
|
run: pnpm install
|
||||||
@@ -38,25 +32,26 @@ jobs:
|
|||||||
run: pnpm build
|
run: pnpm build
|
||||||
|
|
||||||
- name: Build DMG
|
- name: Build DMG
|
||||||
run: pnpm run build:mac -- ${{ matrix.platform }}
|
run: pnpm run build:mac:${{ matrix.platform }}
|
||||||
|
|
||||||
- name: Upload Asset
|
- name: Upload DMG
|
||||||
uses: actions/upload-release-asset@v1
|
uses: actions/upload-artifact@v4
|
||||||
env:
|
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
with:
|
with:
|
||||||
upload_url: ${{ env.UPLOAD_URL }}
|
name: dmg-${{ matrix.platform }}
|
||||||
asset_path: out/${{ matrix.platform }}/WechatExplorer-${{ env.VERSION }}-${{ matrix.platform }}.dmg
|
path: out/mac-*/WechatExplorer-*.dmg
|
||||||
asset_name: WechatExplorer-${{ env.VERSION }}-${{ matrix.platform }}.dmg
|
|
||||||
asset_content_type: application/x-apple-diskimage
|
|
||||||
|
|
||||||
release:
|
release:
|
||||||
needs: build
|
needs: build
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
|
- name: Download artifacts
|
||||||
|
uses: actions/download-artifact@v4
|
||||||
|
with:
|
||||||
|
pattern: dmg-*
|
||||||
|
path: artifacts
|
||||||
|
|
||||||
- name: Create Release
|
- name: Create Release
|
||||||
uses: softprops/action-gh-release@v2
|
uses: softprops/action-gh-release@v2
|
||||||
with:
|
with:
|
||||||
generate_release_notes: true
|
files: artifacts/**/*
|
||||||
env:
|
generate_release_notes: true
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
Reference in New Issue
Block a user