v1.8.0 #429

Merged
LukeGus merged 198 commits from dev-1.8.0 into main 2025-11-05 16:36:16 +00:00
Showing only changes of commit 0250de4b71 - Show all commits

View File

@@ -1,12 +1,25 @@
const { notarize } = require('@electron/notarize');
exports.default = async function notarizing(context) {
const { electronPlatformName, appOutDir } = context;
const { electronPlatformName, appOutDir, packager } = context;
// Skip notarization for non-macOS platforms
if (electronPlatformName !== 'darwin') {
return;
}
// Skip notarization for Mac App Store builds (MAS)
// MAS builds are notarized by Apple during App Store review
const target = packager.platformSpecificBuildOptions.target || [];
const isMasBuild = Array.isArray(target)
? target.some(t => t.target === 'mas' || t === 'mas')
: target === 'mas';
if (isMasBuild || appOutDir.includes('mas')) {
console.log('Skipping notarization for Mac App Store build');
return;
}
const appName = context.packager.appInfo.productFilename;
const appPath = `${appOutDir}/${appName}.app`;
@@ -14,10 +27,13 @@ exports.default = async function notarizing(context) {
const appleIdPassword = process.env.APPLE_APP_SPECIFIC_PASSWORD;
const teamId = process.env.APPLE_TEAM_ID;
// Skip if credentials not provided (for unsigned builds)
if (!appleId || !appleIdPassword || !teamId) {
console.log('Skipping notarization: credentials not provided');
return;
}
console.log('Starting notarization process...');
try {
await notarize({
appPath: appPath,
@@ -25,7 +41,9 @@ exports.default = async function notarizing(context) {
appleIdPassword: appleIdPassword,
teamId: teamId,
});
console.log('Notarization completed successfully');
} catch (error) {
console.error('Notarization failed:', error);
throw error;
}
};