ci: add preliminary windows build setup

This commit is contained in:
talksik
2026-04-14 20:03:16 -07:00
parent c2d0ed254b
commit cee7958e03
3 changed files with 68 additions and 1 deletions
+14 -1
View File
@@ -41,7 +41,20 @@ const config: ForgeConfig = {
rebuildConfig: {},
makers: [
new MakerSquirrel((arch) => ({
remoteReleases: `https://storage.googleapis.com/flowy-releases/llink/win32/${arch}`
remoteReleases: `https://storage.googleapis.com/flowy-releases/llink/win32/${arch}`,
// Windows code signing via Azure Trusted Signing. Dormant unless the workflow
// provisions the dlib + metadata file and exports these env vars, so local
// `yarn make` and unsigned CI builds both work unchanged.
windowsSign: process.env.AZURE_METADATA_JSON_PATH ? {
signWithParams: [
'/v',
'/fd', 'SHA256',
'/tr', 'http://timestamp.acs.microsoft.com',
'/td', 'SHA256',
'/dlib', process.env.AZURE_DLIB_PATH,
'/dmdf', process.env.AZURE_METADATA_JSON_PATH,
].join(' '),
} : undefined,
})),
new MakerZIP((arch) => ({
macUpdateManifestBaseUrl: `https://storage.googleapis.com/flowy-releases/llink/darwin/${arch}`
+1
View File
@@ -9,6 +9,7 @@
"start": "electron-forge start",
"package": "APP_ENV=prod electron-forge package --arch=arm64 && APP_ENV=prod electron-forge package --arch=x64",
"make": "APP_ENV=prod electron-forge make --arch=arm64 && APP_ENV=prod electron-forge make --arch=x64",
"make:win": "electron-forge make --platform=win32 --arch=x64 && electron-forge make --platform=win32 --arch=arm64",
"release": "echo '\n⚠️ Have you bumped the version in package.json? (current: '$(node -p \"require('./package.json').version\")') [y/N]' && read -r answer && [ \"$answer\" = \"y\" ] && APP_ENV=prod electron-forge publish --arch=arm64 && APP_ENV=prod electron-forge publish --arch=x64 && gsutil setmeta -h 'Cache-Control:no-cache, no-store, must-revalidate' gs://flowy-releases/llink/darwin/arm64/RELEASES.json && gsutil setmeta -h 'Cache-Control:no-cache, no-store, must-revalidate' gs://flowy-releases/llink/darwin/x64/RELEASES.json",
"invalidate-gcs-cache": "gsutil -h \"Cache-Control:no-cache, no-store, max-age=0\" cp gs://flowy-releases/llink/darwin/arm64/RELEASES.json gs://flowy-releases/llink/darwin/arm64/RELEASES.json ; gsutil -h \"Cache-Control:no-cache, no-store, max-age=0\" cp gs://flowy-releases/llink/darwin/x64/RELEASES.json gs://flowy-releases/llink/darwin/x64/RELEASES.json",
"lint": "eslint --ext .ts,.tsx .",