From 01e40656cc1ed5fd0a35ca9d62543302cda7a67e Mon Sep 17 00:00:00 2001 From: Guoguo Date: Fri, 26 Dec 2025 15:23:55 +0800 Subject: [PATCH] feat(desktop): add arm64 support ... also add os name in artifact --- .github/workflows/build.yml | 4 ++-- desktop/electron-builder.yml | 8 +++----- desktop/package.json | 5 ++++- 3 files changed, 9 insertions(+), 8 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index d733e95..6891fc9 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -39,7 +39,7 @@ jobs: name: Build Browser Bundle needs: detect-changes runs-on: ubuntu-latest - if: needs.detect-changes.outputs.browser == 'true' + if: github.event_name == 'workflow_dispatch' || needs.detect-changes.outputs.browser == 'true' defaults: run: working-directory: browser @@ -69,7 +69,7 @@ jobs: name: Build Desktop Apps needs: detect-changes runs-on: ${{ matrix.os }} - if: needs.detect-changes.outputs.desktop == 'true' + if: github.event_name == 'workflow_dispatch' || needs.detect-changes.outputs.desktop == 'true' strategy: fail-fast: false matrix: diff --git a/desktop/electron-builder.yml b/desktop/electron-builder.yml index 7573a82..2f531ef 100644 --- a/desktop/electron-builder.yml +++ b/desktop/electron-builder.yml @@ -21,7 +21,7 @@ win: nsis: oneClick: false allowToChangeInstallationDirectory: true - artifactName: ${productName}-${version}-setup.${ext} + artifactName: ${productName}-${version}-${os}-${arch}-setup.${ext} shortcutName: ${productName} uninstallDisplayName: ${productName} createDesktopShortcut: true @@ -39,7 +39,7 @@ mac: notarize: false dmg: - artifactName: ${productName}-${version}.${ext} + artifactName: ${productName}-${version}-${os}-${arch}.${ext} sign: true linux: @@ -49,9 +49,7 @@ linux: - deb maintainer: sipeed.com category: Utility - -appImage: - artifactName: ${productName}-${version}.${ext} + artifactName: "${productName}-${version}-${os}-${arch}.${ext}" npmRebuild: false diff --git a/desktop/package.json b/desktop/package.json index d2a8017..06f330a 100644 --- a/desktop/package.json +++ b/desktop/package.json @@ -17,7 +17,10 @@ "build:unpack": "npm run build && electron-builder --dir", "build:win": "npm run build && electron-builder --win", "build:mac": "electron-vite build && electron-builder --mac", - "build:linux": "electron-vite build && electron-builder --linux" + "build:linux": "electron-vite build && electron-builder --linux", + "build:win-full": "npm run build && electron-builder --win --x64 --arm64", + "build:mac-full": "electron-vite build && electron-builder --mac --x64 --arm64", + "build:linux-full": "electron-vite build && electron-builder --linux --x64 --arm64" }, "dependencies": { "@ant-design/icons": "^5.6.1",