Skip to content

Commit

Permalink
Add team ID to notarization process
Browse files Browse the repository at this point in the history
  • Loading branch information
SleepyLeslie committed May 16, 2024
1 parent b6ecb1f commit 13c4eb2
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
1 change: 1 addition & 0 deletions .github/workflows/package.yml
Original file line number Diff line number Diff line change
Expand Up @@ -97,5 +97,6 @@ jobs:
DEBUG: electron-builder
APPLE_ID: ${{ secrets.APPLE_ID }}
APPLE_ID_PASSWORD: ${{ secrets.APPLE_ID_PASSWORD }}
APPLE_TEAM_ID: ${{ secrets.APPLE_TEAM_ID }}
CSC_KEY_PASSWORD: ${{ secrets.CSC_KEY_PASSWORD }}
CSC_LINK: ${{ secrets.CSC_LINK }}
8 changes: 6 additions & 2 deletions scripts/notarize.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,11 @@ exports.default = async function notarizing(context) {
return;
}
console.log('Notarization begins...')
const appBundleId = context.packager.appInfo.info._configuration.appId;
const appName = context.packager.appInfo.productFilename;
const appPath = path.normalize(path.join(context.appOutDir, `${appName}.app`));
const appleId = process.env.APPLE_ID;
const appleIdPassword = process.env.APPLE_ID_PASSWORD;
const teamId = process.env.APPLE_TEAM_ID;
if (!appleId) {
console.warn('Please set APPLE_ID');
process.exit(1);
Expand All @@ -23,10 +23,14 @@ exports.default = async function notarizing(context) {
console.warn('Please set APPLE_ID_PASSWORD');
process.exit(1);
}
if (!teamId) {
console.warn('Please set TEAM_ID');
process.exit(1);
}
return notarize({
appBundleId,
appPath,
appleId,
appleIdPassword,
teamId
});
};

0 comments on commit 13c4eb2

Please sign in to comment.