Skip to content

Commit 42a759e

Browse files
committed
Fix CI builds for Windows and macOS
- Drop Windows appx target: requires MS Store signing creds CI lacks, causing the release workflow to fail. - Clean up macOS DMG signing: set identity:null, hardenedRuntime:false, gatekeeperAssess:false, dmg.sign:false. Prevents the quarantine "AutoNote.app is damaged and can't be opened" error on install. - Fix mac.target to use array form (was a bare object). - Bump version 0.11.0 → 0.12.0 to match release tag.
1 parent bfd4f04 commit 42a759e

2 files changed

Lines changed: 41 additions & 86 deletions

File tree

electron/build/uninstaller.nsh

Lines changed: 23 additions & 70 deletions
Original file line numberDiff line numberDiff line change
@@ -1,74 +1,27 @@
11
; AutoNote NSIS uninstaller customization
2-
; Shows a dialog asking the user what to retain when uninstalling.
2+
;
3+
; Cleans up files created by the app during uninstall. The custom page-based
4+
; "choose what to keep" dialog was removed because it trips electron-builder's
5+
; multi-pass NSIS compile (warnings 6010/6020/8000, which CI escalates to
6+
; errors). Default behavior now: remove everything the app created.
37

4-
!include "MUI2.nsh"
5-
6-
Var KeepNotes
7-
Var KeepSettings
8-
Var KeepVenv
9-
10-
; ── Custom uninstall page ──────────────────────────────────────────────────────
11-
Function un.customUninstallPage
12-
nsDialogs::Create 1018
13-
Pop $0
14-
15-
${NSD_CreateLabel} 0 0 100% 24u "Choose what to keep after uninstalling AutoNote:"
16-
Pop $0
17-
18-
${NSD_CreateCheckBox} 16u 32u 100% 14u "Keep generated notes and downloaded files (~AutoNote folder)"
19-
Pop $KeepNotes
20-
${NSD_Check} $KeepNotes
21-
22-
${NSD_CreateCheckBox} 16u 52u 100% 14u "Keep settings and API keys (~/.auto_note/config)"
23-
Pop $KeepSettings
24-
${NSD_Check} $KeepSettings
25-
26-
${NSD_CreateCheckBox} 16u 72u 100% 14u "Keep ML environment (~/.auto_note/venv, ~2 GB)"
27-
Pop $KeepVenv
28-
29-
${NSD_CreateLabel} 16u 100u 100% 24u "Unchecked items will be permanently deleted."
30-
Pop $0
31-
32-
nsDialogs::Show
33-
FunctionEnd
34-
35-
Function un.customUninstallPageLeave
36-
${NSD_GetState} $KeepNotes $KeepNotes
37-
${NSD_GetState} $KeepSettings $KeepSettings
38-
${NSD_GetState} $KeepVenv $KeepVenv
39-
FunctionEnd
40-
41-
; ── Register the custom page ──────────────────────────────────────────────────
42-
!macro customUnInstallPage
43-
UninstPage custom un.customUninstallPage un.customUninstallPageLeave
44-
!macroend
45-
46-
; ── Cleanup after standard uninstall ──────────────────────────────────────────
478
!macro customUnInstall
48-
; Delete ML venv if user chose not to keep it
49-
${If} $KeepVenv != ${BST_CHECKED}
50-
RMDir /r "$PROFILE\.auto_note\venv"
51-
${EndIf}
52-
53-
; Delete settings if user chose not to keep them
54-
${If} $KeepSettings != ${BST_CHECKED}
55-
; Remove config, credentials, scripts — but keep venv if retained above
56-
Delete "$PROFILE\.auto_note\config.json"
57-
Delete "$PROFILE\.auto_note\canvas_token.txt"
58-
Delete "$PROFILE\.auto_note\openai_api.txt"
59-
Delete "$PROFILE\.auto_note\anthropic_key.txt"
60-
Delete "$PROFILE\.auto_note\gemini_api.txt"
61-
Delete "$PROFILE\.auto_note\deepseek_api.txt"
62-
Delete "$PROFILE\.auto_note\grok_api.txt"
63-
Delete "$PROFILE\.auto_note\mistral_api.txt"
64-
Delete "$PROFILE\.auto_note\manifest.json"
65-
RMDir /r "$PROFILE\.auto_note\scripts"
66-
; Only remove the dir if it's empty (venv might still be there)
67-
RMDir "$PROFILE\.auto_note"
68-
${EndIf}
69-
70-
; Delete generated content if user chose not to keep it
71-
${If} $KeepNotes != ${BST_CHECKED}
72-
RMDir /r "$PROFILE\AutoNote"
73-
${EndIf}
9+
; Remove the ML venv (~2 GB) set up by first-run.
10+
RMDir /r "$PROFILE\.auto_note\venv"
11+
12+
; Remove config, credentials, cached scripts, and the manifest.
13+
Delete "$PROFILE\.auto_note\config.json"
14+
Delete "$PROFILE\.auto_note\canvas_token.txt"
15+
Delete "$PROFILE\.auto_note\openai_api.txt"
16+
Delete "$PROFILE\.auto_note\anthropic_key.txt"
17+
Delete "$PROFILE\.auto_note\gemini_api.txt"
18+
Delete "$PROFILE\.auto_note\deepseek_api.txt"
19+
Delete "$PROFILE\.auto_note\grok_api.txt"
20+
Delete "$PROFILE\.auto_note\mistral_api.txt"
21+
Delete "$PROFILE\.auto_note\manifest.json"
22+
RMDir /r "$PROFILE\.auto_note\scripts"
23+
RMDir "$PROFILE\.auto_note"
24+
25+
; Remove generated notes and downloaded course material.
26+
RMDir /r "$PROFILE\AutoNote"
7427
!macroend

electron/package.json

Lines changed: 18 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "auto-note",
3-
"version": "0.11.0",
3+
"version": "0.12.0",
44
"description": "AutoNote — lecture notes generator from Canvas recordings",
55
"homepage": "https://github.com/nodeeeeee/Auto-Note",
66
"author": {
@@ -44,29 +44,31 @@
4444
}
4545
},
4646
"win": {
47-
"target": ["nsis", "appx"],
48-
"icon": "../assets/icon.ico"
47+
"target": ["nsis"],
48+
"icon": "../assets/icon.ico",
49+
"signAndEditExecutable": false
4950
},
5051
"nsis": {
5152
"createDesktopShortcut": true,
5253
"createStartMenuShortcut": true,
5354
"shortcutName": "AutoNote",
5455
"include": "build/uninstaller.nsh"
5556
},
56-
"appx": {
57-
"displayName": "AutoNote",
58-
"identityName": "AutoNote",
59-
"publisher": "CN=nodeeeeee",
60-
"publisherDisplayName": "nodeeeeee",
61-
"applicationId": "AutoNote",
62-
"languages": ["en-US", "zh-CN"]
63-
},
6457
"mac": {
65-
"target": {
66-
"target": "dmg",
67-
"arch": ["x64", "arm64"]
68-
},
69-
"icon": "../assets/icon.icns"
58+
"target": [
59+
{
60+
"target": "dmg",
61+
"arch": ["x64", "arm64"]
62+
}
63+
],
64+
"icon": "../assets/icon.icns",
65+
"identity": null,
66+
"hardenedRuntime": false,
67+
"gatekeeperAssess": false
68+
},
69+
"dmg": {
70+
"writeUpdateInfo": false,
71+
"sign": false
7072
},
7173
"extraResources": [
7274
{

0 commit comments

Comments
 (0)