From e207f52f5567d8c01a03db7b1bc3b64a0e34816d Mon Sep 17 00:00:00 2001 From: qer Date: Tue, 30 Jun 2026 22:19:35 +0800 Subject: [PATCH] ci(kimi-desktop): strip Developer ID prefix from CSC_NAME (#1235) * ci(kimi-desktop): strip Developer ID prefix from CSC_NAME electron-builder rejects the 'Developer ID Application: ' prefix in CSC_NAME; the keychain setup exports the full certificate name, so strip the prefix before passing it to electron-builder. * ci(kimi-desktop): add homepage and maintainer for linux .deb electron-builder's .deb target requires a project homepage and a package maintainer; set both so the Linux build succeeds. --- .github/workflows/desktop-build.yml | 11 ++++++++++- apps/kimi-desktop/electron-builder.config.cjs | 1 + apps/kimi-desktop/package.json | 1 + 3 files changed, 12 insertions(+), 1 deletion(-) diff --git a/.github/workflows/desktop-build.yml b/.github/workflows/desktop-build.yml index 8b481d9a6..6c993662b 100644 --- a/.github/workflows/desktop-build.yml +++ b/.github/workflows/desktop-build.yml @@ -118,6 +118,16 @@ jobs: certificate-p12: ${{ secrets.APPLE_CERTIFICATE_P12 }} certificate-password: ${{ secrets.APPLE_CERTIFICATE_PASSWORD }} + - name: Prepare CSC_NAME for electron-builder (macOS) + if: runner.os == 'macOS' && inputs.sign-macos + shell: bash + run: | + # electron-builder rejects the "Developer ID Application: " prefix in + # CSC_NAME; strip it so the certificate matches by team name + ID. + name="${APPLE_SIGNING_IDENTITY}" + name="${name#Developer ID Application: }" + echo "CSC_NAME=$name" >> "$GITHUB_ENV" + - name: Prepare notarization API key (macOS) if: runner.os == 'macOS' && inputs.sign-macos shell: bash @@ -137,7 +147,6 @@ jobs: # API key; otherwise it builds unsigned. CSC_IDENTITY_AUTO_DISCOVERY: ${{ (runner.os == 'macOS' && inputs.sign-macos) && 'true' || 'false' }} CSC_KEYCHAIN: ${{ env.APPLE_KEYCHAIN_PATH }} - CSC_NAME: ${{ env.APPLE_SIGNING_IDENTITY }} KIMI_DESKTOP_NOTARIZE: ${{ (runner.os == 'macOS' && inputs.sign-macos) && 'true' || 'false' }} APPLE_API_KEY_ID: ${{ secrets.APPLE_NOTARIZATION_KEY_ID }} APPLE_API_ISSUER: ${{ secrets.APPLE_NOTARIZATION_ISSUER_ID }} diff --git a/apps/kimi-desktop/electron-builder.config.cjs b/apps/kimi-desktop/electron-builder.config.cjs index e84bff250..edbd20b70 100644 --- a/apps/kimi-desktop/electron-builder.config.cjs +++ b/apps/kimi-desktop/electron-builder.config.cjs @@ -63,5 +63,6 @@ module.exports = { category: 'Development', target: ['AppImage', 'deb'], artifactName: 'KCD-Internal-${version}-${arch}.${ext}', + maintainer: 'Moonshot AI', }, }; diff --git a/apps/kimi-desktop/package.json b/apps/kimi-desktop/package.json index 4c3e44a7d..6501c6ea6 100644 --- a/apps/kimi-desktop/package.json +++ b/apps/kimi-desktop/package.json @@ -5,6 +5,7 @@ "license": "MIT", "description": "Kimi Code desktop client — an Electron shell around the Kimi web UI.", "author": "Moonshot AI", + "homepage": "https://github.com/MoonshotAI/kimi-code", "type": "module", "main": "out/main.cjs", "scripts": {