From b78c652e9c509126a77a3824499ef1a98bb860b3 Mon Sep 17 00:00:00 2001 From: Joshua Melville Date: Tue, 23 Apr 2024 19:25:00 +0200 Subject: [PATCH] update electron notarize package --- build-resources/scripts/afterSignHook.js | 9 +++-- package-lock.json | 44 ++++++++++-------------- package.json | 2 +- 3 files changed, 24 insertions(+), 31 deletions(-) diff --git a/build-resources/scripts/afterSignHook.js b/build-resources/scripts/afterSignHook.js index 15fe3bab0..13eca274a 100644 --- a/build-resources/scripts/afterSignHook.js +++ b/build-resources/scripts/afterSignHook.js @@ -5,11 +5,10 @@ const path = require('path'); const electronNotarize = require('@electron/notarize'); async function note(params) { - // Only notarize the app on Mac OS only. + // Only notarize the app on macOS. if (process.platform !== 'darwin') { return; } - console.log('afterSign hook triggered', params); const appPath = path.join(params.appOutDir, `${params.packager.appInfo.productFilename}.app`); if (!fs.existsSync(appPath)) { @@ -23,9 +22,9 @@ async function note(params) { tool: 'notarytool', appBundleId: 'org.codaco.NetworkCanvasInterviewer6', appPath, - appleApiKey: '~/.private_keys/AuthKey_J58L47W6H9.p8', - appleApiKeyId: 'J58L47W6H9', // This is taken from the filename of the .p8 file in your icloud drive - appleApiIssuer: '69a6de92-60bf-47e3-e053-5b8c7c11a4d1', + appleApiKey: '~/.private_keys/AuthKey_A78M67RCH9.p8', + appleApiKeyId: 'A78M67RCH9', // Taken from https://appstoreconnect.apple.com/access/integrations/api + appleApiIssuer: '69a6de92-60bf-47e3-e053-5b8c7c11a4d1',// As above }); console.log('Done notarizing'); diff --git a/package-lock.json b/package-lock.json index b5b70b84b..d3e705135 100644 --- a/package-lock.json +++ b/package-lock.json @@ -30,7 +30,7 @@ "@codaco/eslint-plugin-spellcheck": "0.0.14", "@codaco/shared-consts": "~0.0.1-alpha.3", "@codaco/ui": "~5.8.5", - "@electron/notarize": "~1.2.3", + "@electron/notarize": "~2.3.0", "@faker-js/faker": "~6.0.0-alpha.5", "@zippytech/sorty": "^2.0.0", "ajv": "^6.5.4", @@ -2886,13 +2886,14 @@ } }, "node_modules/@electron/notarize": { - "version": "1.2.3", - "resolved": "https://registry.npmjs.org/@electron/notarize/-/notarize-1.2.3.tgz", - "integrity": "sha512-9oRzT56rKh5bspk3KpAVF8lPKHYQrBnRwcgiOeR0hdilVEQmszDaAu0IPCPrwwzJN0ugNs0rRboTreHMt/6mBQ==", + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/@electron/notarize/-/notarize-2.3.0.tgz", + "integrity": "sha512-EiTBU0BwE7HZZjAG1fFWQaiQpCuPrVGn7jPss1kUjD6eTTdXXd29RiZqEqkgN7xqt/Pgn4g3I7Saqovanrfj3w==", "dev": true, "dependencies": { "debug": "^4.1.1", - "fs-extra": "^9.0.1" + "fs-extra": "^9.0.1", + "promise-retry": "^2.0.1" }, "engines": { "node": ">= 10.0.0" @@ -8252,9 +8253,9 @@ } }, "node_modules/caniuse-lite": { - "version": "1.0.30001524", - "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001524.tgz", - "integrity": "sha512-Jj917pJtYg9HSJBF95HVX3Cdr89JUyLT4IZ8SvM5aDRni95swKgYi3TgYLH5hnGfPE/U1dg6IfZ50UsIlLkwSA==", + "version": "1.0.30001612", + "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001612.tgz", + "integrity": "sha512-lFgnZ07UhaCcsSZgWW0K5j4e69dK1u/ltrL9lTUiFOwNHs12S3UMIEYgBV0Z6C6hRDev7iRnMzzYmKabYdXF9g==", "dev": true, "funding": [ { @@ -12518,9 +12519,7 @@ "version": "2.0.3", "resolved": "https://registry.npmjs.org/err-code/-/err-code-2.0.3.tgz", "integrity": "sha512-2bmlRpNKBxT/CRmPOlyISQpNj+qSeYvcym/uT0Jx2bMOlKLtSy1ZmLuVxSEKKyor/N5yhvp/ZiG1oE3DEYMSFA==", - "dev": true, - "optional": true, - "peer": true + "dev": true }, "node_modules/errno": { "version": "0.1.8", @@ -26253,8 +26252,6 @@ "resolved": "https://registry.npmjs.org/promise-retry/-/promise-retry-2.0.1.tgz", "integrity": "sha512-y+WKFlBR8BGXnsNlIHFGPZmyDf3DFMoLhaflAnyZgV6rG6xu+JwesTo2Q9R6XwYmtmwAFCkAk3e35jEdoeh/3g==", "dev": true, - "optional": true, - "peer": true, "dependencies": { "err-code": "^2.0.2", "retry": "^0.12.0" @@ -38183,13 +38180,14 @@ } }, "@electron/notarize": { - "version": "1.2.3", - "resolved": "https://registry.npmjs.org/@electron/notarize/-/notarize-1.2.3.tgz", - "integrity": "sha512-9oRzT56rKh5bspk3KpAVF8lPKHYQrBnRwcgiOeR0hdilVEQmszDaAu0IPCPrwwzJN0ugNs0rRboTreHMt/6mBQ==", + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/@electron/notarize/-/notarize-2.3.0.tgz", + "integrity": "sha512-EiTBU0BwE7HZZjAG1fFWQaiQpCuPrVGn7jPss1kUjD6eTTdXXd29RiZqEqkgN7xqt/Pgn4g3I7Saqovanrfj3w==", "dev": true, "requires": { "debug": "^4.1.1", - "fs-extra": "^9.0.1" + "fs-extra": "^9.0.1", + "promise-retry": "^2.0.1" }, "dependencies": { "fs-extra": { @@ -42465,9 +42463,9 @@ } }, "caniuse-lite": { - "version": "1.0.30001524", - "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001524.tgz", - "integrity": "sha512-Jj917pJtYg9HSJBF95HVX3Cdr89JUyLT4IZ8SvM5aDRni95swKgYi3TgYLH5hnGfPE/U1dg6IfZ50UsIlLkwSA==", + "version": "1.0.30001612", + "resolved": "https://registry.npmjs.org/caniuse-lite/-/caniuse-lite-1.0.30001612.tgz", + "integrity": "sha512-lFgnZ07UhaCcsSZgWW0K5j4e69dK1u/ltrL9lTUiFOwNHs12S3UMIEYgBV0Z6C6hRDev7iRnMzzYmKabYdXF9g==", "dev": true }, "capture-exit": { @@ -45785,9 +45783,7 @@ "version": "2.0.3", "resolved": "https://registry.npmjs.org/err-code/-/err-code-2.0.3.tgz", "integrity": "sha512-2bmlRpNKBxT/CRmPOlyISQpNj+qSeYvcym/uT0Jx2bMOlKLtSy1ZmLuVxSEKKyor/N5yhvp/ZiG1oE3DEYMSFA==", - "dev": true, - "optional": true, - "peer": true + "dev": true }, "errno": { "version": "0.1.8", @@ -56334,8 +56330,6 @@ "resolved": "https://registry.npmjs.org/promise-retry/-/promise-retry-2.0.1.tgz", "integrity": "sha512-y+WKFlBR8BGXnsNlIHFGPZmyDf3DFMoLhaflAnyZgV6rG6xu+JwesTo2Q9R6XwYmtmwAFCkAk3e35jEdoeh/3g==", "dev": true, - "optional": true, - "peer": true, "requires": { "err-code": "^2.0.2", "retry": "^0.12.0" diff --git a/package.json b/package.json index 4f20528fe..2eca41f47 100644 --- a/package.json +++ b/package.json @@ -56,7 +56,7 @@ "@codaco/eslint-plugin-spellcheck": "0.0.14", "@codaco/shared-consts": "~0.0.1-alpha.3", "@codaco/ui": "~5.8.5", - "@electron/notarize": "~1.2.3", + "@electron/notarize": "~2.3.0", "@faker-js/faker": "~6.0.0-alpha.5", "@zippytech/sorty": "^2.0.0", "ajv": "^6.5.4",