SEBWIN-300: Integrated custom action into setup to remove leftover files from legacy installations.
This commit is contained in:
parent
79fec35b56
commit
6d328d0501
6 changed files with 16 additions and 5 deletions
7
Setup/LegacyCleanup.wxs
Normal file
7
Setup/LegacyCleanup.wxs
Normal file
|
@ -0,0 +1,7 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi">
|
||||||
|
<Fragment>
|
||||||
|
<CustomAction Id="LegacyCleanupAction" Execute="deferred" Impersonate="no" Return="ignore"
|
||||||
|
Directory="InstallFolder" ExeCommand="cmd.exe /C "rd /S /Q SebWindowsServiceWCF"" />
|
||||||
|
</Fragment>
|
||||||
|
</Wix>
|
|
@ -19,5 +19,8 @@
|
||||||
<ComponentGroupRef Id="ServiceComponents" />
|
<ComponentGroupRef Id="ServiceComponents" />
|
||||||
<ComponentRef Id="ShortcutComponent" />
|
<ComponentRef Id="ShortcutComponent" />
|
||||||
</Feature>
|
</Feature>
|
||||||
|
<InstallExecuteSequence>
|
||||||
|
<Custom Action="LegacyCleanupAction" After="RemoveFiles" />
|
||||||
|
</InstallExecuteSequence>
|
||||||
</Product>
|
</Product>
|
||||||
</Wix>
|
</Wix>
|
||||||
|
|
|
@ -26,6 +26,7 @@
|
||||||
<Compile Include="Components\Reset.wxs" />
|
<Compile Include="Components\Reset.wxs" />
|
||||||
<Compile Include="Components\Service.wxs" />
|
<Compile Include="Components\Service.wxs" />
|
||||||
<Compile Include="Directories.wxs" />
|
<Compile Include="Directories.wxs" />
|
||||||
|
<Compile Include="LegacyCleanup.wxs" />
|
||||||
<Compile Include="Product.wxs" />
|
<Compile Include="Product.wxs" />
|
||||||
<Compile Include="Shortcuts.wxs" />
|
<Compile Include="Shortcuts.wxs" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
|
@ -5,13 +5,13 @@
|
||||||
<Shortcut Id="ApplicationShortcut" Name="Safe Exam Browser" Icon="ApplicationIcon" IconIndex="0" Advertise="no" Directory="ProgramMenuFolder"
|
<Shortcut Id="ApplicationShortcut" Name="Safe Exam Browser" Icon="ApplicationIcon" IconIndex="0" Advertise="no" Directory="ProgramMenuFolder"
|
||||||
Target="[ApplicationDirectory]\$(var.SafeExamBrowser.Runtime.TargetFileName)" WorkingDirectory="ApplicationDirectory"
|
Target="[ApplicationDirectory]\$(var.SafeExamBrowser.Runtime.TargetFileName)" WorkingDirectory="ApplicationDirectory"
|
||||||
Description="Starts the main application." />
|
Description="Starts the main application." />
|
||||||
<Shortcut Id="ConfigurationToolShortcut" Name="SEB Configuration Tool" Icon="ConfigurationToolIcon" IconIndex="0" Advertise="no" Directory="StartMenuDirectory"
|
<Shortcut Id="ConfigurationToolShortcut" Name="SEB Configuration Tool" Icon="ConfigurationToolIcon" IconIndex="0" Advertise="no"
|
||||||
Target="[ConfigurationDirectory]\$(var.SebWindowsConfig.TargetFileName)" WorkingDirectory="ConfigurationDirectory"
|
Target="[ConfigurationDirectory]\$(var.SebWindowsConfig.TargetFileName)" WorkingDirectory="ConfigurationDirectory"
|
||||||
Description="Provides options to edit configuration files for the main application." />
|
Description="Provides options to edit configuration files for the main application." />
|
||||||
<Shortcut Id="ResetUtilityShortcut" Name="SEB Reset Utility" Icon="ApplicationIcon" IconIndex="0" Advertise="no" Directory="StartMenuDirectory"
|
<Shortcut Id="ResetUtilityShortcut" Name="SEB Reset Utility" Icon="ApplicationIcon" IconIndex="0" Advertise="no"
|
||||||
Target="[ResetDirectory]\$(var.SafeExamBrowser.ResetUtility.TargetFileName)" WorkingDirectory="ResetDirectory"
|
Target="[ResetDirectory]\$(var.SafeExamBrowser.ResetUtility.TargetFileName)" WorkingDirectory="ResetDirectory"
|
||||||
Description="Provides options to reset any changes made by the main application." />
|
Description="Provides options to reset any changes made by the main application." />
|
||||||
<RemoveFolder Id="StartMenuDirectory" On="uninstall" />
|
<RemoveFolder Id="RemoveStartMenuDirectory" On="uninstall" />
|
||||||
<RegistryValue Root="HKCU" Key="Software\[Manufacturer]\[ProductName]" Name="installed" Type="integer" Value="1" KeyPath="yes" />
|
<RegistryValue Root="HKCU" Key="Software\[Manufacturer]\[ProductName]" Name="installed" Type="integer" Value="1" KeyPath="yes" />
|
||||||
</Component>
|
</Component>
|
||||||
</Fragment>
|
</Fragment>
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
UpgradeCode="26C1045A-99CC-4479-987B-376390379441" IconSourceFile="$(var.Setup.ProjectDir)Resources\Application.ico">
|
UpgradeCode="26C1045A-99CC-4479-987B-376390379441" IconSourceFile="$(var.Setup.ProjectDir)Resources\Application.ico">
|
||||||
<BootstrapperApplicationRef Id="WixStandardBootstrapperApplication.RtfLargeLicense">
|
<BootstrapperApplicationRef Id="WixStandardBootstrapperApplication.RtfLargeLicense">
|
||||||
<bal:WixStandardBootstrapperApplication LicenseFile="$(var.Setup.ProjectDir)Resources\License.rtf" ThemeFile="Resources\Theme.xml"
|
<bal:WixStandardBootstrapperApplication LicenseFile="$(var.Setup.ProjectDir)Resources\License.rtf" ThemeFile="Resources\Theme.xml"
|
||||||
LocalizationFile="Resources\Theme.wxl" ShowVersion="yes" SuppressOptionsUI="yes" SuppressRepair="yes" />
|
LocalizationFile="Resources\Theme.wxl" SuppressOptionsUI="yes" SuppressRepair="yes" />
|
||||||
</BootstrapperApplicationRef>
|
</BootstrapperApplicationRef>
|
||||||
<Chain>
|
<Chain>
|
||||||
<PackageGroupRef Id="DotNetFramework" />
|
<PackageGroupRef Id="DotNetFramework" />
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
<!-- Original File Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. -->
|
<!-- Original File Copyright (c) .NET Foundation and contributors. All rights reserved. Licensed under the Microsoft Reciprocal License. -->
|
||||||
|
|
||||||
<Theme xmlns="http://wixtoolset.org/schemas/thmutil/2010">
|
<Theme xmlns="http://wixtoolset.org/schemas/thmutil/2010">
|
||||||
<Window Width="500" Height="400" HexStyle="100a0000" FontId="0">#(loc.Caption)</Window>
|
<Window Width="525" Height="450" HexStyle="100a0000" FontId="0">#(loc.Caption)</Window>
|
||||||
<Font Id="0" Height="-12" Weight="500" Foreground="000000" Background="F0F0F0">Segoe UI</Font>
|
<Font Id="0" Height="-12" Weight="500" Foreground="000000" Background="F0F0F0">Segoe UI</Font>
|
||||||
<Font Id="1" Height="-24" Weight="750" Foreground="000000" Background="F0F0F0">Segoe UI</Font>
|
<Font Id="1" Height="-24" Weight="750" Foreground="000000" Background="F0F0F0">Segoe UI</Font>
|
||||||
<Font Id="2" Height="-22" Weight="500" Foreground="444444" Background="F0F0F0">Segoe UI</Font>
|
<Font Id="2" Height="-22" Weight="500" Foreground="444444" Background="F0F0F0">Segoe UI</Font>
|
||||||
|
|
Loading…
Reference in a new issue