OSDN Git Service

v1.7.6
[serene/MyBrowser.git] / build-mac.js
1 const builder = require('electron-builder');
2 const fs = require('fs');
3 const pkg = JSON.parse(fs.readFileSync('./app/package.json', 'utf8'));
4
5 builder.build({
6     platform: 'mac',
7     config: {
8         'appId': `org.aoichaan0513.${pkg.name}`,
9         'productName': pkg.name,
10         'copyright': `Copyright 2019 ${pkg.author.name}. All rights reserved.`,
11         'asar': true,
12         'publish': {
13             'provider': 'generic',
14             'url': `http://aoichaan0513.xyz/flast/${process.platform}/${process.arch}/${pkg.flast_channel}`,
15             'channel': pkg.flast_channel
16         },
17         'fileAssociations': [
18             {
19                 'name': 'Document',
20                 'description': pkg.name,
21                 'role': 'Viewer',
22                 'ext': 'html'
23             }
24         ],
25         'mac': {
26             'target': 'dmg',
27             'icon': './static/icon.png',
28         },
29     },
30 });