Repository navigation
Expand file tree
/
Copy pathelectron-builder.yml
More file actions
195 lines (181 loc) · 7.76 KB
/
Copy pathelectron-builder.yml
File metadata and controls
195 lines (181 loc) · 7.76 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
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
appId: com.helmryth.app
productName: Helmryth
artifactName: Helmryth-${version}-${arch}.${ext}
protocols:
- name: Helmryth capability install
schemes: [helmryth]
# Publishing is intentionally disabled until a Helmryth-owned release host,
# signing identity, and update repository have been provisioned. Packaging
# scripts already pass `--publish never`; omitting `publish` also prevents a
# personal or unowned repository from being baked into installed clients.
# Guarded release scripts validate HELMRYTH_RELEASE_REPO and generate a private
# temporary config that adds exactly that destination; local builds never do.
directories:
buildResources: build
output: release
# electron-builder makes copied directories group-writable by default. The
# Linux CUA trust boundary requires root-owned package ancestors to be 0755.
afterPack: ./scripts/after-pack.mjs
# The built UI (Vite -> ui/) and the compiled harness server (tsc -> server/)
# are each bundled before packaging and run on Electron's own Node via
# ELECTRON_RUN_AS_NODE, so their dependencies are already inside them and must
# not be copied a second time — that is what the blanket node_modules
# exclusion below is for.
#
# The Electron main and preload are the exception: they are NOT bundled. They
# ship as plain .mjs/.cjs and resolve their imports at runtime from inside the
# asar, so every package they import has to be put back explicitly after that
# exclusion. `pnpm check:packaged` fails the build when one is missing, which
# is otherwise only discoverable by packaging the app and launching it.
files:
- electron/**
- "!electron/**/*.test.*"
# `*.test.*` does not match `*.node-test.mjs` — there is no `.test.`
# substring in that name — so nine test modules were being signed into
# the asar. Both shapes are excluded now, and a case in
# scripts/check-packaged-imports.test.mjs holds this list to the same
# definition of "test module" the packaged-import gate already uses.
- "!electron/**/*.node-test.*"
- "!electron/resources/speech-helper"
- "!electron/resources/speech-helper.swift"
- "!electron/resources/speech-helper-Info.plist"
- "!electron/resources/Helmryth Speech.app/**"
- "!electron/resources/recorder-helper"
- "!electron/resources/recorder-helper.swift"
- "!electron/resources/recorder-helper-Info.plist"
- "!electron/resources/Helmryth Recorder.app/**"
- "!**/node_modules/**"
# Imported at module scope by managed-composio.mjs, registry-client.mjs and
# companion-account-service.mjs. Omitting it does not degrade a feature — the
# app dies before any window opens with ERR_MODULE_NOT_FOUND. zod declares no
# dependencies of its own, so this one entry is the whole subtree.
- node_modules/zod/**
- package.json
asar: true
extraResources:
# Ship the app's own license terms in every desktop distribution.
- from: LICENSE
to: licenses/Helmryth-LICENSE.txt
- from: NOTICE
to: licenses/Helmryth-NOTICE.txt
# cloudflared is distributed under Apache-2.0 as a separate executable.
# Helmryth itself uses the same full license text; ship another named
# copy so the third-party executable's terms remain unambiguous.
- from: LICENSE
to: licenses/cloudflared-LICENSE.txt
- from: third_party/cloudflared/README.md
to: licenses/cloudflared-README.md
- from: dist
to: ui
- from: dist-server
to: server
# the companion sidecar — a separate process because it is the only part
# of the app that listens off this machine, and it stays off until asked
- from: dist-companion
to: companion
- from: skills
to: skills
- from: dist-native/android-platform-tools
to: android-platform-tools
mac:
# Two single-arch artifacts rather than one universal binary: the app is
# ~177 MB per arch, and universal would make every user download both halves.
# A future provisioned updater will pick by filename (arm64-marked files on
# Apple silicon, unmarked ones on Intel).
target:
- target: dmg
arch: [arm64, x64]
- target: zip
arch: [arm64, x64]
icon: build/icon.icns
category: public.app-category.productivity
hardenedRuntime: true
gatekeeperAssess: false
entitlements: build/entitlements.mac.plist
entitlementsInherit: build/entitlements.mac.plist
# the dictation helper is a signed background app — Windows and Linux never see it
extraResources:
- from: electron/resources/Helmryth Speech.app
to: Helmryth Speech.app
- from: electron/resources/Helmryth Recorder.app
to: Helmryth Recorder.app
# CUA must live outside ASAR. prepare-cua stages the signed executable and
# a self-contained JS/native SDK bundle selected for macOS arm64.
# ${arch} resolves per built arch — each bundle carries its own natives
- from: dist-native/${arch}/cua-driver
to: cua-driver
- from: dist-native/${arch}/cua-sdk
to: cua-sdk
- from: dist-native/cloudflared/darwin-${arch}/cloudflared
to: cloudflared/cloudflared
extendInfo:
NSMicrophoneUsageDescription: Helmryth uses the microphone for voice dictation into the composer.
NSSpeechRecognitionUsageDescription: Helmryth transcribes your voice on-device to type messages for you.
NSAccessibilityUsageDescription: Helmryth uses Accessibility when you let an operator control this Mac.
NSScreenCaptureUsageDescription: Helmryth uses Screen Recording so operators can see this Mac before acting.
# Notarization runs manually after the build with notarytool + staple.
notarize: false
dmg:
sign: true
# ${arch} is load-bearing: without it the x64 dmg silently overwrites
# the arm64 one when both arches build (this section overrides both the
# top-level and mac-level artifactName, so it must carry the arch itself)
artifactName: Helmryth-${version}-${arch}.dmg
win:
target:
- target: nsis
arch: x64
- target: zip
arch: x64
icon: build/icon.ico
extraResources:
- from: dist-native/cloudflared/win32-x64/cloudflared.exe
to: cloudflared/cloudflared.exe
# Local packaging stays unsigned and publish-free on purpose. The protected
# release overlay injects Authenticode settings, publisherName, and the
# release-only managed-services config at packaging time.
nsis:
oneClick: true
perMachine: false
shortcutName: Helmryth
# Versioned, like the .dmg. The README's /latest/download/ button needs a
# STABLE filename, so ship a second copy named Helmryth-setup.exe on the
# release — the same trick as Helmryth.dmg beside Helmryth-${version}.dmg.
artifactName: Helmryth-${version}-setup.${ext}
linux:
target:
- target: AppImage
arch: x64
- target: deb
arch: x64
# Keep the vector source in the freedesktop scalable icon hierarchy. A
# lone 1024px PNG is not indexed by GNOME's hicolor theme on Ubuntu 24.04.
icon: build/icon.svg
category: Utility
executableName: helmryth
synopsis: The work moves. You hold the helm.
description: A private operating system for autonomous work.
maintainer: Helmryth Contributors
vendor: Helmryth
syncDesktopName: true
# The reviewed x64 CLI runtime is staged before packaging and remains
# outside ASAR so executable modes and adjacent sidecars are preserved.
extraResources:
- from: dist-native/cua-linux-x64
to: cua-linux-x64
- from: dist-native/cloudflared/linux-x64/cloudflared
to: cloudflared/cloudflared
desktop:
entry:
Name: Helmryth
Comment: The work moves. You hold the helm.
Keywords: Operators;Workstreams;Automation;Productivity;
deb:
packageCategory: utils
priority: optional
# dpkg can preserve legacy directory modes during an upgrade. This
# idempotent hook repairs only the exact package-owned CUA path.
afterInstall: build/linux-after-install.sh
# Static AppImage runtime: Ubuntu 24.04 can launch it without legacy FUSE 2.
toolsets:
appimage: "1.0.3"