Skip to content

Commit eaa6831

Browse files
SteveL-MSFTTravisEz13
authored andcommitted
Add title to Open Here window for MSI installer (#8164)
Since we don't explicitly set the window title, it just shows the path to `pwsh.exe`. Fix is to use the `-Command` parameter to set the window title. Fix #8163
1 parent c5c747c commit eaa6831

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

assets/Product.wxs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -207,15 +207,15 @@
207207
<RegistryValue Type="string" Name="Icon" Value="[$(var.ProductDirectoryName)]$(env.IconPath)"/>
208208
</RegistryKey>
209209
<RegistryKey Root="HKCR" Key="Directory\ContextMenus\$(var.ProductName)$(var.SimpleProductVersion)$(sys.BUILDARCH)\shell\openpwsh\command">
210-
<RegistryValue Type="string" Value="[$(var.ProductDirectoryName)]pwsh.exe -NoExit -WorkingDirectory &quot;%V&quot; "/>
210+
<RegistryValue Type="string" Value="[$(var.ProductDirectoryName)]pwsh.exe -NoExit -WorkingDirectory &quot;%V&quot; -Command &quot;$host.UI.RawUI.WindowTitle = '$(var.ProductName) $(var.SimpleProductVersion) ($(sys.BUILDARCH))'&quot;"/>
211211
</RegistryKey>
212212
<RegistryKey Root="HKCR" Key="Directory\ContextMenus\$(var.ProductName)$(var.SimpleProductVersion)$(sys.BUILDARCH)\shell\runas">
213213
<RegistryValue Type="string" Name="MUIVerb" Value="$(var.ExplorerContextSubMenuElevatedDialogText)"/>
214214
<RegistryValue Type="string" Name="Icon" Value="[$(var.ProductDirectoryName)]$(env.IconPath)"/>
215215
<RegistryValue Type="string" Value="" Name="HasLUAShield"/>
216216
</RegistryKey>
217217
<RegistryKey Root="HKCR" Key="Directory\ContextMenus\$(var.ProductName)$(var.SimpleProductVersion)$(sys.BUILDARCH)\shell\runas\command">
218-
<RegistryValue Type="string" Value="[$(var.ProductDirectoryName)]pwsh.exe -NoExit -WorkingDirectory &quot;%V&quot; "/>
218+
<RegistryValue Type="string" Value="[$(var.ProductDirectoryName)]pwsh.exe -NoExit -WorkingDirectory &quot;%V&quot; -Command &quot;$host.UI.RawUI.WindowTitle = '$(var.ProductName) $(var.SimpleProductVersion) ($(sys.BUILDARCH))'&quot;"/>
219219
</RegistryKey>
220220
</Component>
221221
</Directory>

0 commit comments

Comments
 (0)