diff options
| author | Christoph Berg <myon@debian.org> | 2026-06-22 12:03:44 +0200 |
|---|---|---|
| committer | Christoph Berg <myon@debian.org> | 2026-06-22 12:03:44 +0200 |
| commit | d83a420f0517d7fc47aeb288a6a0cf4891784fcc (patch) | |
| tree | 6d9c83527c56458a8360ba080bf5f4ca73d526dc /CMake/Modules/NSIS.template.in | |
| parent | 4b089ae3f7e9e2d5662f718f663b26a4e8ee63ca (diff) | |
New upstream version 3.0.2+dfsgupstream/3.0.2+dfsg
Diffstat (limited to 'CMake/Modules/NSIS.template.in')
| -rw-r--r-- | CMake/Modules/NSIS.template.in | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/CMake/Modules/NSIS.template.in b/CMake/Modules/NSIS.template.in index 9e171e28..b14a8623 100644 --- a/CMake/Modules/NSIS.template.in +++ b/CMake/Modules/NSIS.template.in @@ -970,6 +970,22 @@ SectionEnd ; "Program Files" for AllUsers, "My Documents" for JustMe... Function .onInit + ; --- WSJT-X running-process check (custom) --- + ; Abort cleanly if WSJT-X is already running, to avoid a half-installed + ; mess when the user upgrades over a live instance. Uses tasklist+findstr + ; (built into every supported Windows version) so no NSIS plugin is + ; required. + wsjtx_running_check: + nsExec::Exec '"$SYSDIR\cmd.exe" /c tasklist /FI "IMAGENAME eq wsjtx.exe" 2>NUL | $SYSDIR\findstr.exe /I "wsjtx.exe" >NUL' + Pop $0 + ${If} $0 == "0" + MessageBox MB_RETRYCANCEL|MB_ICONEXCLAMATION \ + "WSJT-X is currently running. $\n$\nPlease close it before installing or upgrading." \ + /SD IDCANCEL IDRETRY wsjtx_running_check + Abort + ${EndIf} + ; --- end WSJT-X running-process check --- + Push $0 Push $1 Push $2 |
