chore: Add windows icon in desktop
This commit is contained in:
1 parent
89891a401a
commit
4f0e2794ec
4 files changed
+7
-6
No files matched your search
@@ -11,12 +11,12 @@ const artifactDestination = path.resolve(__dirname, '..', 'cli');
|
||||
const downloadArtifact = (version) => {
|
||||
const archivePlatform = {};
|
||||
// TODO: Support all available build machines
|
||||
if (isMac) {
|
||||
if (isMac()) {
|
||||
archivePlatform.name = 'darwin';
|
||||
archivePlatform.arch = 'amd64';
|
||||
}
|
||||
|
||||
if (isWindows) {
|
||||
if (isWindows()) {
|
||||
archivePlatform.name = 'windows';
|
||||
archivePlatform.arch = 'amd64';
|
||||
}
|
||||
|
||||
@@ -32,8 +32,7 @@ const createConfig = () => {
|
||||
// Version
|
||||
if (config.RELEASE_VERSION)
|
||||
config.packagerConfig.version = config.RELEASE_VERSION;
|
||||
|
||||
if (isMac) {
|
||||
if (isMac()) {
|
||||
config.packagerConfig.icon = './config/macos/icon.icns';
|
||||
config.packagerConfig.osxSign = {
|
||||
'hardened-runtime': true,
|
||||
@@ -64,7 +63,9 @@ const createConfig = () => {
|
||||
});
|
||||
}
|
||||
|
||||
if (isWindows) {
|
||||
if (isWindows()) {
|
||||
config.packagerConfig.icon = './config/windows/icon.ico';
|
||||
|
||||
// Generate EXE file
|
||||
config.makers.push({
|
||||
name: '@electron-forge/maker-squirrel',
|
||||
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 11 KiB |
@@ -1,6 +1,6 @@
|
||||
const os = require('os');
|
||||
|
||||
module.exports = {
|
||||
isMac: () => Boolean(os.type().match(/darwin/i)),
|
||||
isMac: () => Boolean(os.type().match(/(darwin)/i)),
|
||||
isWindows: () => Boolean(os.type().match(/(windows)/i)),
|
||||
};
|
||||
Reference in new issue
Block a user