-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathelectron-builder.yml
More file actions
121 lines (120 loc) · 6.05 KB
/
Copy pathelectron-builder.yml
File metadata and controls
121 lines (120 loc) · 6.05 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
appId: com.dbbaskette.meetingnotes
productName: MeetingNotes
directories:
output: release
files:
- dist/**
- package.json
# Strip better-sqlite3 build artifacts we don't need at runtime. The
# native module itself (build/Release/better_sqlite3.node, ~1.8 MB) is
# all that's required; everything below is source code, build-time
# intermediates, or SQLite's bundled C tree that electron-rebuild
# already consumed. Each `!` entry here is negated against the include
# globs above — electron-builder's defaults pull in production
# node_modules, so we're trimming the fat on top of that. Drops about
# 19 MB from app.asar (34 MB → ~15 MB).
- "!**/node_modules/better-sqlite3/deps/**"
- "!**/node_modules/better-sqlite3/src/**"
- "!**/node_modules/better-sqlite3/build/deps/**"
- "!**/node_modules/better-sqlite3/build/Release/obj/**"
- "!**/node_modules/better-sqlite3/build/Release/obj.target/**"
- "!**/node_modules/better-sqlite3/build/Release/.deps/**"
- "!**/node_modules/better-sqlite3/build/Release/test_extension.node"
- "!**/node_modules/better-sqlite3/build/Makefile"
- "!**/node_modules/better-sqlite3/build/config.gypi"
- "!**/node_modules/better-sqlite3/build/*.mk"
# Drop dev-only artifacts that prod node_modules ship anyway. The remark/
# mdast tree alone leaks 263 .map files (~1.5 MB after asar compression)
# plus a .d.ts.map next to every .d.ts. Type stubs (.d.ts) ride along
# because tsc emits them next to .js — runtime ignores them.
- "!**/node_modules/**/*.map"
- "!**/node_modules/**/*.d.ts"
- "!**/node_modules/**/*.d.ts.map"
# README / CHANGELOG / HISTORY files are pure docs — none of MIT, BSD,
# or Apache-2 require redistributing them. (We deliberately KEEP
# LICENSE, NOTICE, and AUTHORS files; MIT/Apache-2 mandate license-text
# redistribution, and BSD/Apache-2 have an authors-attribution clause.)
- "!**/node_modules/**/{README,README.md,README.markdown,readme,readme.md}"
- "!**/node_modules/**/{CHANGELOG,CHANGELOG.md,HISTORY.md}"
# zod 3.25.x ships THREE copies of itself: the classic v3 API (what
# `import { z } from 'zod'` resolves to — index.cjs requires ./v3/),
# plus opt-in `zod/v4` + `zod/v4-mini` subpaths and the TypeScript
# sources in src/. Nothing here imports the v4 subpaths (verified: v3
# is self-contained, no ../v4 requires), so drop the dead ~4.4 MB.
# KEEP v3/ — that IS the runtime code.
- "!**/node_modules/zod/src/**"
- "!**/node_modules/zod/v4/**"
- "!**/node_modules/zod/v4-mini/**"
# @vscode/ripgrep ships a per-platform native binary (powers Cmd+K
# search) via optionalDependencies — the real binary lives in
# @vscode/ripgrep-${platform}-${arch}/bin/rg. Binaries can't be exec'd
# from inside an asar archive, so unpack the bin/ folder into
# app.asar.unpacked. The JS shim (@vscode/ripgrep itself, which
# resolves the platform pkg at runtime) still rides inside the asar.
asarUnpack:
- "node_modules/@vscode/ripgrep-*/bin/**"
extraResources:
# Ship only the PyInstaller bundle — the user does not need Python installed.
# Dev runs out of the source tree where the .venv path is used instead.
- from: sidecar/dist/meeting-notes-diarize
to: sidecar/dist/meeting-notes-diarize
filter:
- "**/*"
- from: sidecar
to: sidecar
filter:
- "meeting_notes_diarize/**/*.py"
- "BUILD_ID"
- "!**/__pycache__/**"
- "!**/*.pyc"
# Built-in audio capture helper. Bundled inside MeetingNotes.app so that
# macOS attributes the audio-capture TCC request to the parent app's stable
# signed identity (a bare CLI binary cannot be granted Privacy & Security
# access reliably).
- from: audio-tap/build/meeting-notes-tap
to: bin/meeting-notes-tap
mac:
# App/dock/Finder icon. Built from build/icon-1024.png (the logo on a dark
# rounded-square card) via iconutil — keep that PNG to regenerate the icns.
# electron-builder would auto-detect build/icon.icns, but we name it
# explicitly so the bundle icon's source is unambiguous.
icon: build/icon.icns
target:
- dmg
- zip
category: public.app-category.productivity
hardenedRuntime: true
# Register meetingnotes:// as a URL scheme so external callers (Shortcuts,
# CLI `open`, Alfred/Raycast actions) can trigger record / stop / open
# programmatically. Handled by electron/main/url-scheme/dispatcher.ts. (#77)
protocols:
- name: MeetingNotes
schemes:
- meetingnotes
role: Editor
# Custom entitlements add com.apple.security.device.audio-input to both the
# parent .app and every signed child binary (electron-builder uses the same
# plist for both unless entitlementsInherit is overridden). The bundled
# meeting-notes-tap helper inherits via entitlementsInherit so the audio
# entitlement survives electron-builder's re-sign of the extraResources.
entitlements: build/entitlements.mac.plist
entitlementsInherit: build/entitlements.mac.plist
# NSMicrophoneUsageDescription / NSAudioCaptureUsageDescription strings come
# from the helper's embedded Info.plist; the parent .app uses Electron's
# bundled Info.plist (Electron prompts on first getMediaAccessStatus call
# only if asked — we let the helper own the prompts).
extendInfo:
NSMicrophoneUsageDescription: MeetingNotes records meetings by capturing your microphone.
NSAudioCaptureUsageDescription: MeetingNotes records meetings by capturing audio from other apps.
# Post-package hook trims dead weight from Chromium's bundled Electron
# Framework. Strips ~55 unused locale .lproj dirs (~37 MB across 50+
# languages) AND the software-WebGL fallback libs `libvk_swiftshader.dylib`
# + `libGLESv2.dylib` (~23 MB), since MeetingNotes renders no
# WebGL/Canvas3D surface and Apple Silicon's hardware path always wins.
# See build/trim-electron-framework.cjs for the full rationale + risk
# tradeoffs.
afterPack: build/trim-electron-framework.cjs
# Maximum compression on dmg/zip. Slower build (adds ~30–60s of LZMA at
# higher settings) for ~5–10 MB off the download. The installed .app size
# is unaffected; this only shrinks the artifacts users download.
compression: maximum