Skip to content

Commit 395a630

Browse files
committed
add nullsoft installer
1 parent b29aa4f commit 395a630

File tree

124 files changed

+8309
-4
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

124 files changed

+8309
-4
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -194,3 +194,4 @@ ModelManifest.xml
194194
LittleBigMouse/Control.Loader/setup/*.exe
195195
/LittleBigMouse/Control.Loader/img/Logos/Intel
196196
/LittleBigMouse.Setup/LittleBigMouse_5.0.0.0.exe
197+
*.exe

LittleBigMouse.Setup/LittleBigMouse.iss

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ Name: "{group}\Little Big Mouse"; Filename: "{app}\LittleBigMouse.Ui.Avalonia.ex
3131
[Run]
3232
Filename: {app}\LittleBigMouse.Ui.Avalonia.exe; Description: Run Application; Flags: postinstall nowait skipifsilent runascurrentuser
3333

34-
[UninstallRun]
35-
Filename: "{cmd}"; Parameters: "/C ""taskkill /im LittleBigMouse.Ui.Avalonia.exe /f /t"
36-
Filename: "{cmd}"; Parameters: "/C ""taskkill /im LittleBigMouse.Hook.exe /f /t"
37-
Filename: "{app}\LittleBigMouse_Daemon.exe"; Parameters: "--unschedule --exit"
34+
;[UninstallRun]
35+
;Filename: "{cmd}"; Parameters: "/C ""taskkill /im LittleBigMouse.Ui.Avalonia.exe /f /t"
36+
;Filename: "{cmd}"; Parameters: "/C ""taskkill /im LittleBigMouse.Hook.exe /f /t"
37+
;Filename: "{app}\LittleBigMouse_Daemon.exe"; Parameters: "--unschedule --exit"
Lines changed: 119 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,119 @@
1+
;--------------------------------
2+
;Include Modern UI
3+
4+
!include "MUI2.nsh"
5+
6+
!define lbm "LittleBigMouse"
7+
!define lbm_version "5.0.0"
8+
!define lbm_file "LittleBigMouse.Ui.Avalonia.exe"
9+
10+
11+
!define main "..\LittleBigMouse.Ui\LittleBigMouse.Ui.Avalonia"
12+
!define daemon "..\LittleBigMouse.Daemon"
13+
!define main_out_dir "${main}\bin\x64\Release\net8.0"
14+
!define daemon_out_dir "${daemon}\bin\x64\Release"
15+
16+
;--------------------------------
17+
;General
18+
19+
;Name and file
20+
Name "Little Big Mouse"
21+
OutFile "${lbm}-${lbm_version}.exe"
22+
Unicode True
23+
24+
;Default installation folder
25+
InstallDir "$PROGRAMFILES64\${lbm}"
26+
27+
;Get installation folder from registry if available
28+
InstallDirRegKey HKCU "Software\Mgth\${lbm}" ""
29+
30+
;Request application privileges for Windows Vista
31+
RequestExecutionLevel admin
32+
33+
;---------------------------------
34+
;General
35+
36+
!define MUI_ICON "${main}\MainIcon.ico"
37+
!define MUI_UNICON "${main}\MainIcon.ico"
38+
; !define MUI_SPECIALBITMAP "Bitmap.bmp"
39+
40+
;--------------------------------
41+
;Interface Settings
42+
43+
!define MUI_ABORTWARNING
44+
45+
;--------------------------------
46+
;Pages
47+
48+
; !insertmacro MUI_PAGE_LICENSE "${NSISDIR}\Docs\Modern UI\License.txt"
49+
; !insertmacro MUI_PAGE_COMPONENTS
50+
!insertmacro MUI_PAGE_DIRECTORY
51+
!insertmacro MUI_PAGE_INSTFILES
52+
53+
!define MUI_FINISHPAGE_RUN "$INSTDIR\${lbm_file}"
54+
!insertmacro MUI_PAGE_FINISH
55+
56+
!insertmacro MUI_UNPAGE_CONFIRM
57+
!insertmacro MUI_UNPAGE_INSTFILES
58+
59+
60+
;--------------------------------
61+
;Language
62+
63+
!insertmacro MUI_LANGUAGE "English"
64+
65+
66+
;--------------------------------
67+
;Installer Sections
68+
Section "install"
69+
70+
;Add files
71+
SetOutPath "$INSTDIR"
72+
73+
File "${main_out_dir}\*.exe"
74+
File "${daemon_out_dir}\*.exe"
75+
File /r "${main_out_dir}\*.dll"
76+
File "${main_out_dir}\*.json"
77+
78+
;create desktop shortcut
79+
CreateShortCut "$DESKTOP\${lbm}.lnk" "$INSTDIR\${lbm_file}" ""
80+
81+
;create start-menu items
82+
CreateDirectory "$SMPROGRAMS\${lbm}"
83+
CreateShortCut "$SMPROGRAMS\${lbm}\Uninstall.lnk" "$INSTDIR\Uninstall.exe" "" "$INSTDIR\Uninstall.exe" 0
84+
CreateShortCut "$SMPROGRAMS\${lbm}\${lbm}.lnk" "$INSTDIR\${lbm_file}" "" "$INSTDIR\${lbm_file}" 0
85+
86+
;write uninstall information to the registry
87+
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${lbm}" "DisplayName" "${lbm} (remove only)"
88+
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\${lbm}" "UninstallString" "$INSTDIR\Uninstall.exe"
89+
90+
WriteUninstaller "$INSTDIR\Uninstall.exe"
91+
92+
SectionEnd
93+
94+
95+
;--------------------------------
96+
;Uninstaller Section
97+
Section "Uninstall"
98+
99+
;Delete Files
100+
RMDir /r "$INSTDIR\*.*"
101+
102+
;Remove the installation directory
103+
RMDir "$INSTDIR"
104+
105+
;Delete Start Menu Shortcuts
106+
Delete "$DESKTOP\${lbm}.lnk"
107+
Delete "$SMPROGRAMS\${lbm}\*.*"
108+
RmDir "$SMPROGRAMS\${lbm}"
109+
110+
;Delete Uninstaller And Unistall Registry Entries
111+
; DeleteRegKey HKEY_LOCAL_MACHINE "SOFTWARE\${lbm}"
112+
DeleteRegKey HKEY_LOCAL_MACHINE "SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\${lbm}"
113+
114+
SectionEnd
115+
116+
117+
118+
119+
;eof
-843 KB
Binary file not shown.
-843 KB
Binary file not shown.
-863 KB
Binary file not shown.
-927 KB
Binary file not shown.
-928 KB
Binary file not shown.
-1.12 MB
Binary file not shown.
-1.12 MB
Binary file not shown.

0 commit comments

Comments
 (0)