From 335711368bc2159fefcd2d753b3fb1508ebe0b1f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EC=A1=B0=ED=98=84=EC=9A=B1=5BSW=EA=B5=90=EC=9C=A1?= =?UTF-8?q?=ED=94=8C=EB=9E=AB=ED=8F=BC=EA=B0=9C=EB=B0=9C=5D?= Date: Wed, 27 Mar 2024 15:46:19 +0900 Subject: [PATCH] =?UTF-8?q?feat:=20notarytool=20=EC=82=AC=EC=9A=A9?= =?UTF-8?q?=EC=9D=84=20=EC=9C=84=ED=95=B4=20teamID=20=EC=B6=94=EA=B0=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- scripts/notarize.js | 8 +++++--- scripts/notarize_app.js | 3 ++- scripts/notarize_installer.js | 3 ++- 3 files changed, 9 insertions(+), 5 deletions(-) diff --git a/scripts/notarize.js b/scripts/notarize.js index 813d6ea20..61d28024f 100644 --- a/scripts/notarize.js +++ b/scripts/notarize.js @@ -1,7 +1,7 @@ const { notarize } = require('electron-notarize'); module.exports = async function notarizing(notarizeOption) { - const { appBundleId, appPath, appleId, appleIdPassword } = notarizeOption; + const { appBundleId, appPath, appleId, appleIdPassword, teamId } = notarizeOption; const { NOTARIZE } = process.env; // noinspection EqualityComparisonWithCoercionJS @@ -10,8 +10,8 @@ module.exports = async function notarizing(notarizeOption) { return; } - if (!appleId || !appleIdPassword) { - console.log(' • APPLE_ID or APPLE_PASSWORD not found. will be skipped this process'); + if (!appleId || !appleIdPassword || !teamId) { + console.log(' • APPLE_ID or APPLE_PASSWORD or TEAM_ID not found. will be skipped this process'); return; } @@ -21,9 +21,11 @@ module.exports = async function notarizing(notarizeOption) { appleId: ${appleId}`, ); return await notarize({ + tool: 'notarytool', appBundleId, appPath, appleId, + teamId, appleIdPassword, }); }; diff --git a/scripts/notarize_app.js b/scripts/notarize_app.js index 01c1ff10f..902bba13f 100644 --- a/scripts/notarize_app.js +++ b/scripts/notarize_app.js @@ -3,7 +3,7 @@ const notarize = require('./notarize'); module.exports = async function notarizing(context) { const { appOutDir } = context; const { electronPlatformName } = context; - const { APPLE_ID, APPLE_PASSWORD } = process.env; + const { APPLE_ID, APPLE_PASSWORD, TEAM_ID } = process.env; if (electronPlatformName !== 'darwin') { return; @@ -15,6 +15,7 @@ module.exports = async function notarizing(context) { appBundleId: 'org.playentry.entry', appPath: `${appOutDir}/${appName}.app`, appleId: APPLE_ID, + teamId: TEAM_ID, appleIdPassword: APPLE_PASSWORD, }); }; diff --git a/scripts/notarize_installer.js b/scripts/notarize_installer.js index 8dc038e94..d26e5d652 100644 --- a/scripts/notarize_installer.js +++ b/scripts/notarize_installer.js @@ -3,7 +3,7 @@ const notarize = require('./notarize'); module.exports = async (context) => { const { artifactPaths } = context; - const { APPLE_ID, APPLE_PASSWORD } = process.env; + const { APPLE_ID, APPLE_PASSWORD, TEAM_ID } = process.env; return await Promise.all(artifactPaths.map(async (artifactPath) => { if (path.extname(artifactPath) === '.pkg') { @@ -11,6 +11,7 @@ module.exports = async (context) => { appBundleId: 'org.playentry.entry', appPath: artifactPath, appleId: APPLE_ID, + teamId: TEAM_ID, appleIdPassword: APPLE_PASSWORD, }); }