Skip to content

Commit

Permalink
osx sign and notarization
Browse files Browse the repository at this point in the history
  • Loading branch information
simonrho committed Aug 8, 2024
1 parent b7ca999 commit 4ed1333
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 167 deletions.
40 changes: 11 additions & 29 deletions jccm/forge.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,12 @@ const { FuseV1Options, FuseVersion } = require('@electron/fuses');
console.log(`Current working directory: ${process.cwd()}`);

const entitlements = '/Users/srho/electron-test/juniper-jccm-project/jccm/entitlements.plist';

module.exports = {
packagerConfig: {
asar: true,
icon: './assets/icons/AppIcon', // Path without the extension
osxSign: {
'hardened-runtime': true,
identity: `Developer ID Application: ${process.env.APPLE_DEVELOPER_NAME} (${process.env.APPLE_DEVELOPER_TEAM_ID})`,
},
osxNotarize: {
appleId: process.env.APPLE_ID,
Expand Down Expand Up @@ -66,7 +64,6 @@ module.exports = {
out: path.join(__dirname, 'out/make/darwin-arm64'),
name: 'jccm-darwin-arm64',
arch: 'arm64',
platforms: ['darwin'],
},
},
{
Expand All @@ -78,34 +75,19 @@ module.exports = {
out: path.join(__dirname, 'out/make/darwin-x64'),
name: 'jccm-darwin-x64',
arch: 'x64',
platforms: ['darwin'],
},
},
{
name: '@electron-forge/maker-pkg',
config: {
identity: `Developer ID Installer: ${process.env.APPLE_DEVELOPER_NAME} (${process.env.APPLE_DEVELOPER_TEAM_ID})`,
overwrite: true,
out: path.join(__dirname, 'out/make/macos-pkg'),
name: 'jccm-darwin-arm64',
icon: path.join(__dirname, 'assets/icons/AppIcon.icns'), // Use the same icon as for DMG
arch: 'arm64',
platforms: ['darwin'],
}
},
{
name: '@electron-forge/maker-pkg',
config: {
identity: `Developer ID Installer: ${process.env.APPLE_DEVELOPER_NAME} (${process.env.APPLE_DEVELOPER_TEAM_ID})`,
overwrite: true,
out: path.join(__dirname, 'out/make/macos-pkg'),
name: 'jccm-darwin-x64',
icon: path.join(__dirname, 'assets/icons/AppIcon.icns'), // Use the same icon as for DMG
arch: 'x64',
platforms: ['darwin'],
}
}

// {
// name: '@electron-forge/maker-pkg',
// config: {
// identity: `Developer ID Installer: ${process.env.APPLE_DEVELOPER_NAME} (${process.env.APPLE_DEVELOPER_TEAM_ID})`,
// overwrite: true,
// out: path.join(__dirname, 'out/make/macos-pkg'),
// name: 'jccm-macos-pkg',
// icon: path.join(__dirname, 'assets/icons/AppIcon.icns'), // Use the same icon as for DMG
// arch: ['x64', 'arm64'] // Support both architectures
// }
// }
],
plugins: [
{
Expand Down
14 changes: 2 additions & 12 deletions jccm/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,28 +8,20 @@
"start": "pkill -9 node; nodemon --watch ./src --ext js,json --ignore ./src/Frontend/ --exec 'electron-forge start'",
"package": "electron-forge package",
"make": "electron-forge make",
"make:dmg": "electron-forge make --platform=darwin --arch=arm64 --arch=x64 --targets=@electron-forge/maker-dmg",
"make:pkg": "electron-forge make --platform=darwin --arch=arm64 --arch=x64 --targets=@electron-forge/maker-pkg",
"make:arm64-darwin-dmg": "electron-forge make --platform=darwin --arch=arm64 --targets=@electron-forge/maker-dmg",
"make:x64-darwin-dmg": "electron-forge make --platform=darwin --arch=x64 --targets=@electron-forge/maker-dmg",
"make:arm64-darwin-pkg": "electron-forge make --platform=darwin --arch=arm64 --targets=@electron-forge/maker-pkg",
"make:x64-darwin-pkg": "electron-forge make --platform=darwin --arch=x64 --targets=@electron-forge/maker-pkg",
"publish": "electron-forge publish",
"lint": "echo \"No linting configured\""
},
"devDependencies": {
"@electron-forge/cli": "^7.4.0",
"@electron-forge/maker-deb": "^7.4.0",
"@electron-forge/maker-dmg": "^7.4.0",
"@electron-forge/maker-pkg": "^7.4.0",
"@electron-forge/maker-rpm": "^7.4.0",
"@electron-forge/maker-squirrel": "^7.4.0",
"@electron-forge/maker-zip": "^7.4.0",
"@electron-forge/plugin-auto-unpack-natives": "^7.4.0",
"@electron-forge/plugin-fuses": "^7.4.0",
"@electron-forge/plugin-webpack": "^7.4.0",
"@electron/fuses": "^1.8.0",
"@electron/universal": "^2.0.1",
"@vercel/webpack-asset-relocator-loader": "1.7.3",
"concurrently": "^8.2.2",
"css-loader": "^6.0.0",
Expand All @@ -38,9 +30,7 @@
"nodemon": "^3.1.0",
"stream-browserify": "^3.0.0",
"style-loader": "^3.0.0",
"svg-inline-loader": "^0.8.2",
"uglify-js": "^3.19.1",
"webpack-node-externals": "^3.0.0"
"svg-inline-loader": "^0.8.2"
},
"keywords": [],
"author": {
Expand Down Expand Up @@ -95,4 +85,4 @@
"xterm-addon-fit": "^0.8.0",
"zustand": "^4.5.2"
}
}
}
34 changes: 0 additions & 34 deletions jccm/webpack.main.config copy.js

This file was deleted.

46 changes: 0 additions & 46 deletions jccm/webpack.renderer.config copy.js

This file was deleted.

46 changes: 0 additions & 46 deletions jccm/webpack.rules copy.js

This file was deleted.

0 comments on commit 4ed1333

Please sign in to comment.