-
Notifications
You must be signed in to change notification settings - Fork 27
/
electron-build.js
61 lines (59 loc) · 1.09 KB
/
electron-build.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
"use strict";
const builder = require("electron-builder");
const Platform = builder.Platform;
builder.build({
targets: Platform.WINDOWS.createTarget(),
config: {
"appId": "com.bodastage.bodalite",
"productName": "Boda-Lite",
"copyright": "Copyright © 2023 ${author}",
"files": [
"./build/**/*",
"./main.js",
"package.json"
],
"extraMetadata": {
"main": "./main.js"
},
"dmg": {
"contents": [
{
"x": 110,
"y": 150
},
{
"x": 240,
"y": 150,
"type": "link",
"path": "/Applications"
}
]
},
"linux": {
"target": [
"AppImage",
"deb"
]
},
"win": {
"target": "NSIS",
"icon": "build/icon.ico"
},
"directories": {
"buildResources": "assets"
},
"publish": {
"provider": "github",
"owner": "bodastage",
"repo": "bts-ce-lite",
"private": false
}
}
})
.then(() => {
console.log('Build OK!');
})
.catch((error) => {
// handle error
console.log(error);
})