Skip to content

Commit c655cef

Browse files
Make PATH addition optional in installer and remove unwanted screens
- Change installer UI from WixUI_Minimal to WixUI_FeatureTree to show feature selection - Create separate 'Add to PATH' feature that users can select/deselect - Default PATH addition to enabled (Level=1) but allow user choice - Skip license dialog since we don't have a license file - Update completion message to be conditional on PATH selection - Apply changes to all installer scripts: - GitHub workflow (.github/workflows/build-installers.yml) - Test script with UI (test-windows-installer-with-ui.ps1) - Main test script (test-windows-installer.ps1) Users now get a clean installer experience with optional PATH addition.
1 parent 3869ad1 commit c655cef

File tree

2 files changed

+22
-12
lines changed

2 files changed

+22
-12
lines changed

.github/workflows/build-installers.yml

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -78,20 +78,28 @@ jobs:
7878
<MediaTemplate EmbedCab="yes" />
7979
8080
<!-- Add UI -->
81-
<UIRef Id="WixUI_Minimal" />
81+
<UIRef Id="WixUI_FeatureTree" />
8282
<UIRef Id="WixUI_ErrorProgressText" />
8383
84+
<!-- Skip license dialog since we don't have a license file -->
85+
<Publish Dialog="WelcomeDlg" Control="Next" Event="NewDialog" Value="CustomizeDlg" Order="2">1</Publish>
86+
<Publish Dialog="CustomizeDlg" Control="Back" Event="NewDialog" Value="WelcomeDlg" Order="2">1</Publish>
87+
8488
<!-- Custom completion message -->
85-
<Property Id="WIXUI_EXITDIALOGOPTIONALTEXT" Value="Digstore has been successfully installed. Please restart your terminal or log out and back in for PATH changes to take effect." />
89+
<Property Id="WIXUI_EXITDIALOGOPTIONALTEXT" Value="Digstore has been successfully installed. If you selected 'Add to PATH', please restart your terminal or log out and back in for PATH changes to take effect." />
8690
8791
<!-- Remove custom action as it's causing ICE77 error -->
8892
<!-- File associations will be refreshed on next login -->
8993
90-
<Feature Id="ProductFeature" Title="Digstore Min" Level="1" Display="expand">
94+
<Feature Id="ProductFeature" Title="Digstore Min" Level="1" Display="expand" ConfigurableDirectory="INSTALLFOLDER">
9195
<ComponentGroupRef Id="ProductComponents" />
92-
<ComponentRef Id="Path" />
9396
<ComponentRef Id="ProgramMenuDir" />
9497
<ComponentRef Id="FileAssociation" />
98+
99+
<!-- Separate feature for PATH addition - optional but default enabled -->
100+
<Feature Id="PathFeature" Title="Add to PATH" Description="Add Digstore to system PATH environment variable" Level="1" Display="expand">
101+
<ComponentRef Id="Path" />
102+
</Feature>
95103
</Feature>
96104
97105
<Directory Id="TARGETDIR" Name="SourceDir">

test-windows-installer-with-ui.ps1

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -43,22 +43,24 @@ Write-Host "Creating WiX file with UI..." -ForegroundColor Green
4343
<MediaTemplate EmbedCab="yes" />
4444
4545
<!-- Add UI Reference -->
46-
<UIRef Id="WixUI_InstallDir" />
46+
<UIRef Id="WixUI_FeatureTree" />
4747
<UIRef Id="WixUI_ErrorProgressText" />
4848
49-
<!-- Set the default installation directory -->
50-
<Property Id="WIXUI_INSTALLDIR" Value="INSTALLFOLDER" />
51-
52-
<!-- License file (optional - we'll skip it for now) -->
53-
<WixVariable Id="WixUILicenseRtf" Value="installer\windows\license.rtf" Overridable="yes" />
49+
<!-- Skip license dialog since we don't have a license file -->
50+
<Publish Dialog="WelcomeDlg" Control="Next" Event="NewDialog" Value="CustomizeDlg" Order="2">1</Publish>
51+
<Publish Dialog="CustomizeDlg" Control="Back" Event="NewDialog" Value="WelcomeDlg" Order="2">1</Publish>
5452
5553
<!-- Custom dialog text -->
56-
<Property Id="WIXUI_EXITDIALOGOPTIONALTEXT" Value="Digstore has been successfully installed. Please restart your terminal or log out and back in for PATH changes to take effect." />
54+
<Property Id="WIXUI_EXITDIALOGOPTIONALTEXT" Value="Digstore has been successfully installed. If you selected 'Add to PATH', please restart your terminal or log out and back in for PATH changes to take effect." />
5755
5856
<Feature Id="ProductFeature" Title="Digstore Min" Level="1" Display="expand" ConfigurableDirectory="INSTALLFOLDER">
5957
<ComponentGroupRef Id="ProductComponents" />
60-
<ComponentRef Id="Path" />
6158
<ComponentRef Id="ProgramMenuDir" />
59+
60+
<!-- Separate feature for PATH addition - optional but default enabled -->
61+
<Feature Id="PathFeature" Title="Add to PATH" Description="Add Digstore to system PATH environment variable" Level="1" Display="expand">
62+
<ComponentRef Id="Path" />
63+
</Feature>
6264
</Feature>
6365
6466
<Directory Id="TARGETDIR" Name="SourceDir">

0 commit comments

Comments
 (0)