-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.js
42 lines (41 loc) · 1.24 KB
/
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
const builder = require('electron-builder');
const { productname } = require('./package.json');
builder.build({
config: {
publish: [
{
provider: "github",
owner: "1ly4s0",
repo: "flashexplorer",
releaseType: "release"
}
],
generateUpdatesFilesForAllChannels: true,
appId: productname,
productName: productname,
artifactName: '${productName}-${os}-${arch}.${ext}',
files: ["src/**/*", "package.json", "LICENSE.md"],
directories: { "output": "dist" },
compression: 'maximum',
asar: true,
win: {
icon: "./src/assets/images/icons/icon.ico",
target: [{
target: "nsis",
arch: ["x64", "ia32"]
}]
},
nsis: {
oneClick: false,
allowToChangeInstallationDirectory: true,
createDesktopShortcut: true,
runAfterFinish: true,
multiLanguageInstaller: true,
license: "./LICENSE",
}
}
}).then(() => {
console.log('✅ El build se ha realizado correctamente.')
}).catch(err => {
console.error('Error al realizar el build', err)
})