name: Build & Release on: push: tags: - 'v*' jobs: build: runs-on: macos-latest strategy: matrix: platform: [x64, arm64] steps: - name: Checkout uses: actions/checkout@v4 - name: Setup Node.js uses: actions/setup-node@v4 with: node-version: '20' cache: 'pnpm' - name: Install pnpm run: npm install -g pnpm@7 - name: Install Dependencies run: pnpm install - name: Build run: pnpm build - name: Build DMG run: pnpm run build:mac:${{ matrix.platform }} - name: Upload DMG uses: actions/upload-artifact@v4 with: name: dmg-${{ matrix.platform }} path: out/mac-*/WechatExplorer-*.dmg release: needs: build runs-on: ubuntu-latest steps: - name: Download artifacts uses: actions/download-artifact@v4 with: pattern: dmg-* path: artifacts - name: Create Release uses: softprops/action-gh-release@v2 with: files: artifacts/**/* generate_release_notes: true