mirror of
https://github.com/arsvendg/Stirling-PDF.git
synced 2026-07-14 10:34:06 +02:00
95 lines
4.7 KiB
XML
95 lines
4.7 KiB
XML
<?xml version="1.0" encoding="UTF-8"?>
|
|
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi">
|
|
<Fragment>
|
|
<Property Id="STIRLING_SERVER_URL" Secure="yes" />
|
|
<Property Id="STIRLING_LOCK_CONNECTION" Secure="yes" />
|
|
<!--
|
|
STIRLING_UPDATE_MODE — headless auto-update policy for MDM/Intune deploys.
|
|
Accepts "prompt" (default, user-interactive), "auto" (silent download+install on
|
|
startup), or "disabled" (never check). Leaving it unset preserves whatever was
|
|
configured on the previous install (or defaults to "prompt" on a fresh install).
|
|
-->
|
|
<Property Id="STIRLING_UPDATE_MODE" Secure="yes" />
|
|
|
|
<DirectoryRef Id="TARGETDIR">
|
|
<Directory Id="AppDataFolder" />
|
|
<Directory Id="CommonAppDataFolder" />
|
|
</DirectoryRef>
|
|
|
|
<DirectoryRef Id="INSTALLDIR">
|
|
<Component Id="ProvisionerBinaryComponent" Guid="*">
|
|
<File Id="ProvisionerExe" Source="$(sys.SOURCEFILEDIR)stirling-provision.exe" KeyPath="yes" />
|
|
</Component>
|
|
<Component Id="ThumbnailHandlerDllComponent" Guid="*">
|
|
<File Id="ThumbnailHandlerDll" Source="$(sys.SOURCEFILEDIR)stirling_thumbnail_handler.dll" KeyPath="yes" />
|
|
</Component>
|
|
</DirectoryRef>
|
|
|
|
<!-- PDF Thumbnail Handler COM registration -->
|
|
<DirectoryRef Id="TARGETDIR">
|
|
<Component Id="ThumbnailHandlerClsidComponent" Guid="*">
|
|
<RegistryKey Root="HKLM" Key="SOFTWARE\Classes\CLSID\{2D2FBE3A-9A88-4308-A52E-7EF63CA7CF48}">
|
|
<RegistryValue Type="string" Value="Stirling-PDF Thumbnail Handler" KeyPath="yes" />
|
|
</RegistryKey>
|
|
<RegistryKey Root="HKLM" Key="SOFTWARE\Classes\CLSID\{2D2FBE3A-9A88-4308-A52E-7EF63CA7CF48}\InprocServer32">
|
|
<RegistryValue Type="string" Value="[INSTALLDIR]stirling_thumbnail_handler.dll" />
|
|
<RegistryValue Type="string" Name="ThreadingModel" Value="Apartment" />
|
|
</RegistryKey>
|
|
</Component>
|
|
<Component Id="ThumbnailHandlerShellexComponent" Guid="*">
|
|
<RegistryKey Root="HKLM" Key="SOFTWARE\Classes\.pdf\shellex\{E357FCCD-A995-4576-B01F-234630154E96}">
|
|
<RegistryValue Type="string" Value="{2D2FBE3A-9A88-4308-A52E-7EF63CA7CF48}" KeyPath="yes" />
|
|
</RegistryKey>
|
|
</Component>
|
|
</DirectoryRef>
|
|
|
|
<ComponentGroup Id="ProvisioningComponentGroup">
|
|
<ComponentRef Id="ProvisionerBinaryComponent" />
|
|
<ComponentRef Id="ThumbnailHandlerDllComponent" />
|
|
<ComponentRef Id="ThumbnailHandlerClsidComponent" />
|
|
<ComponentRef Id="ThumbnailHandlerShellexComponent" />
|
|
</ComponentGroup>
|
|
|
|
<CustomAction
|
|
Id="WriteProvisioningFilePerUser"
|
|
FileKey="ProvisionerExe"
|
|
Execute="deferred"
|
|
Impersonate="yes"
|
|
Return="check"
|
|
ExeCommand="[WriteProvisioningFilePerUser]"
|
|
/>
|
|
|
|
<CustomAction
|
|
Id="WriteProvisioningFileAllUsers"
|
|
FileKey="ProvisionerExe"
|
|
Execute="deferred"
|
|
Impersonate="no"
|
|
Return="check"
|
|
ExeCommand="[WriteProvisioningFileAllUsers]"
|
|
/>
|
|
|
|
<CustomAction
|
|
Id="SetWriteProvisioningFilePerUser"
|
|
Property="WriteProvisioningFilePerUser"
|
|
Value="--output "[AppDataFolder]Stirling-PDF\stirling-provisioning.json" --url "[STIRLING_SERVER_URL]" --lock "[STIRLING_LOCK_CONNECTION]" --update-mode "[STIRLING_UPDATE_MODE]""
|
|
/>
|
|
|
|
<CustomAction
|
|
Id="SetWriteProvisioningFileAllUsers"
|
|
Property="WriteProvisioningFileAllUsers"
|
|
Value="--output "[CommonAppDataFolder]Stirling-PDF\stirling-provisioning.json" --url "[STIRLING_SERVER_URL]" --lock "[STIRLING_LOCK_CONNECTION]" --update-mode "[STIRLING_UPDATE_MODE]""
|
|
/>
|
|
|
|
<!--
|
|
Run the provisioner when EITHER STIRLING_SERVER_URL or STIRLING_UPDATE_MODE is set.
|
|
The provisioner is a no-op if both values end up empty, so passing neither is safe.
|
|
-->
|
|
<InstallExecuteSequence>
|
|
<Custom Action="SetWriteProvisioningFilePerUser" After="InstallFiles">(STIRLING_SERVER_URL <> "" OR STIRLING_UPDATE_MODE <> "") AND (NOT ALLUSERS OR ALLUSERS=0)</Custom>
|
|
<Custom Action="WriteProvisioningFilePerUser" After="SetWriteProvisioningFilePerUser">(STIRLING_SERVER_URL <> "" OR STIRLING_UPDATE_MODE <> "") AND (NOT ALLUSERS OR ALLUSERS=0)</Custom>
|
|
<Custom Action="SetWriteProvisioningFileAllUsers" After="InstallFiles">(STIRLING_SERVER_URL <> "" OR STIRLING_UPDATE_MODE <> "") AND (ALLUSERS=1 OR ALLUSERS=2)</Custom>
|
|
<Custom Action="WriteProvisioningFileAllUsers" After="SetWriteProvisioningFileAllUsers">(STIRLING_SERVER_URL <> "" OR STIRLING_UPDATE_MODE <> "") AND (ALLUSERS=1 OR ALLUSERS=2)</Custom>
|
|
</InstallExecuteSequence>
|
|
</Fragment>
|
|
</Wix>
|