[Installer] Check if swift application is running before (un-)installation

ref T33
This commit is contained in:
Roland Winklmeier
2018-09-17 14:16:25 +02:00
committed by Klaus Basan
parent 8ed01b0259
commit 8a4b101393

View File

@@ -24,6 +24,49 @@
</include>
</componentList>
<preInstallationActionList>
<actionGroup>
<explanation>Check that no swift applications running</explanation>
<actionList>
<showWarning>
<ruleEvaluationLogic>or</ruleEvaluationLogic>
<text>It seems that some swift application is still in use, please close
it and relaunch the installer.</text>
</showWarning>
<exit>
<exitCode>1</exitCode>
</exit>
</actionList>
<ruleList>
<ruleGroup>
<ruleList>
<ruleGroup>
<ruleEvaluationLogic>or</ruleEvaluationLogic>
<ruleList>
<processTest>
<logic>is_running</logic>
<name>swiftcore.exe</name>
</processTest>
<processTest>
<logic>is_running</logic>
<name>swiftguistd.exe</name>
</processTest>
<processTest>
<logic>is_running</logic>
<name>swiftlauncher.exe</name>
</processTest>
<processTest>
<logic>is_running</logic>
<name>swiftdata.exe</name>
</processTest>
</ruleList>
</ruleGroup>
<platformTest>
<type>windows</type>
</platformTest>
</ruleList>
</ruleGroup>
</ruleList>
</actionGroup>
<!-- TODO Linux/MacOS: Save and load last install dir -->
<setInstallerVariable>
<name>installBaseDir</name>
@@ -144,6 +187,49 @@
</writeFile>
</postInstallationActionList>
<preUninstallationActionList>
<actionGroup>
<explanation>Check that no swift applications running</explanation>
<actionList>
<showWarning>
<ruleEvaluationLogic>or</ruleEvaluationLogic>
<text>It seems that some swift application is still in use, please close
it and relaunch the uninstaller.</text>
</showWarning>
<exit>
<exitCode>1</exitCode>
</exit>
</actionList>
<ruleList>
<ruleGroup>
<ruleList>
<ruleGroup>
<ruleEvaluationLogic>or</ruleEvaluationLogic>
<ruleList>
<processTest>
<logic>is_running</logic>
<name>swiftcore.exe</name>
</processTest>
<processTest>
<logic>is_running</logic>
<name>swiftguistd.exe</name>
</processTest>
<processTest>
<logic>is_running</logic>
<name>swiftlauncher.exe</name>
</processTest>
<processTest>
<logic>is_running</logic>
<name>swiftdata.exe</name>
</processTest>
</ruleList>
</ruleGroup>
<platformTest>
<type>windows</type>
</platformTest>
</ruleList>
</ruleGroup>
</ruleList>
</actionGroup>
<deleteFile>
<path>${installdir}/update.ini</path>
</deleteFile>