forked from ssbc/patchwork
-
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathelectron-builder.config.js
More file actions
118 lines (103 loc) · 3.3 KB
/
electron-builder.config.js
File metadata and controls
118 lines (103 loc) · 3.3 KB
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
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
// Modified from ManyVerse, adapted to Patchwork
// SPDX-FileCopyrightText: 2021-2022 The Manyverse Authors
//
// SPDX-License-Identifier: CC0-1.0
const path = require("path");
const rimraf = require("rimraf");
const packageJSON = require("./package.json");
const copyrightYear = new Date().getFullYear();
const AUTHOR = "The Scuttlebutt Consortium";
const NAME_HUMAN = "Poncho Wonky";
const NAME_COMPUTER = "ponchowonky";
module.exports = {
// Metadata ------------------------------------------------------------------
appId: "org.ssbc.ponchowonky",
productName: NAME_HUMAN,
copyright: `${copyrightYear} ${AUTHOR}`,
buildVersion: packageJSON.version,
extraMetadata: {
name: NAME_COMPUTER,
version: packageJSON.version,
description: "A social network for the rest of us",
author: AUTHOR,
homepage: "https://scuttlebutt.nz",
license: "AGPL-3.0",
repository: "https://github.com/soapdog/patchwork/",
},
protocols: [{ name: "ssb", schemes: ["ssb"] }],
// Files section
files: [
"!*.p12",
"!*.sh",
"!*.lua",
],
// Electron-builder options --------------------------------------------------
asar: false,
npmRebuild: false,
electronVersion: packageJSON.devDependencies.electron,
// All things files and directories ------------------------------------------
directories: {
app: __dirname,
buildResources: path.join(__dirname, "build"),
output: path.join(__dirname, "dist"),
},
// Linux-specific configurations ---------------------------------------------
linux: {
icon: path.join(__dirname, "build", "512x512.png"),
target: [
{ target: "deb", arch: ["x64", "arm64"] },
{ target: "tar.gz", arch: ["x64", "arm64"] },
{ target: "AppImage", arch: ["x64", "arm64"] },
],
category: "Network",
maintainer: "André Alves Garzia <andre@andregarzia.com>",
},
deb: {
packageCategory: "net",
priority: "optional",
depends: [
"libnotify4",
"libxtst6",
"libnss3",
"libc6 >= 2.28",
// Disabled to support KDE:
// 'gconf2',
// 'gconf-service',
// Disabled to support Debian 10+:
// 'libappindicator1',
],
},
appImage: {
artifactName: "${name}-${version}-linux-${arch}.${ext}",
},
// Mac-specific configurations -----------------------------------------------
mac: {
icon: path.join(__dirname, "build", "512x512.png"),
category: "public.app-category.social-networking",
darkModeSupport: true,
target: [{ target: "dmg", arch: "x64" }, { target: "dmg", arch: "arm64" }],
hardenedRuntime: true,
type: "distribution",
entitlements: "build/entitlements.mac.plist",
entitlementsInherit: "build/entitlements.mac.plist",
x64ArchFiles: "**/*.node",
},
dmg: {
icon: path.join(__dirname, "build", "512x512.png"),
// background: path.join(__dirname, 'build', 'dmg-background.png'),
},
// Windows-specific configurations -------------------------------------------
nsis: {
artifactName: "${name}-${version}-windows-${arch}-nsis-installer.${ext}",
oneClick: false,
perMachine: false,
},
// Publish options -----------------------------------------------------------
publish: {
provider: "github",
protocol: "https",
owner: "soapdog",
repo: "patchwork",
releaseType: "release",
},
};