Skip to content

Commit d7370cf

Browse files
authored
Refactor MSI CI (#14753)
1 parent ac560d8 commit d7370cf

File tree

9 files changed

+43
-40
lines changed

9 files changed

+43
-40
lines changed

.vsts-ci/windows/windows-packaging.yml

Lines changed: 34 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -8,14 +8,17 @@ trigger:
88
- release*
99
- feature*
1010
paths:
11-
include:
12-
- /.vsts-ci/templates/windows-packaging.yml
13-
- /.vsts-ci/windows-packaging.yml
14-
- /global.json
15-
- /src/*
16-
- /tools/ci.psm1
17-
- /tools/packaging/*
18-
- /assets/*
11+
exclude:
12+
- tests/*
13+
- docs/*
14+
- demos/*
15+
- CHANGELOG/*
16+
- .devcontainer/*
17+
- .github/*
18+
- .poshchan/*
19+
- .vscode/*
20+
- code-server/*
21+
- docker/*
1922

2023
pr:
2124
branches:
@@ -27,29 +30,29 @@ pr:
2730
# file extension filters are not supported when this was written.
2831
# This really should be /src/**/*.csproj
2932
include:
30-
- /.vsts-ci/templates/windows-packaging.yml
31-
- /.vsts-ci/windows-packaging.yml
32-
- /global.json
33-
- /src/Microsoft.Management.Infrastructure.CimCmdlets/Microsoft.Management.Infrastructure.CimCmdlets.csproj
34-
- /src/Microsoft.Management.UI.Internal/Microsoft.PowerShell.GraphicalHost.csproj
35-
- /src/Microsoft.PowerShell.Commands.Diagnostics/Microsoft.PowerShell.Commands.Diagnostics.csproj
36-
- /src/Microsoft.PowerShell.Commands.Management/Microsoft.PowerShell.Commands.Management.csproj
37-
- /src/Microsoft.PowerShell.Commands.Utility/Microsoft.PowerShell.Commands.Utility.csproj
38-
- /src/Microsoft.PowerShell.ConsoleHost/Microsoft.PowerShell.ConsoleHost.csproj
39-
- /src/Microsoft.PowerShell.CoreCLR.Eventing/Microsoft.PowerShell.CoreCLR.Eventing.csproj
40-
- /src/Microsoft.PowerShell.GlobalTool.Shim/Microsoft.PowerShell.GlobalTool.Shim.csproj
41-
- /src/Microsoft.PowerShell.LocalAccounts/Microsoft.PowerShell.LocalAccounts.csproj
42-
- /src/Microsoft.PowerShell.MarkdownRender/Microsoft.PowerShell.MarkdownRender.csproj
43-
- /src/Microsoft.PowerShell.SDK/Microsoft.PowerShell.SDK.csproj
44-
- /src/Microsoft.PowerShell.Security/Microsoft.PowerShell.Security.csproj
45-
- /src/Microsoft.WSMan.Management/Microsoft.WSMan.Management.csproj
46-
- /src/Microsoft.WSMan.Runtime/Microsoft.WSMan.Runtime.csproj
47-
- /src/Modules/PSGalleryModules.csproj
48-
- /src/powershell-win-core/powershell-win-core.csproj
49-
- /tools/ci.psm1
50-
- /tools/packaging/*
51-
- /assets/files.wxs
52-
- /assets/Product.wxs
33+
- .vsts-ci/windows/*
34+
- assets/wix/*
35+
- build.psm1
36+
- global.json
37+
- nuget.config
38+
- PowerShell.Common.props
39+
- src/Microsoft.Management.Infrastructure.CimCmdlets/Microsoft.Management.Infrastructure.CimCmdlets.csproj
40+
- src/Microsoft.Management.UI.Internal/Microsoft.PowerShell.GraphicalHost.csproj
41+
- src/Microsoft.PowerShell.Commands.Diagnostics/Microsoft.PowerShell.Commands.Diagnostics.csproj
42+
- src/Microsoft.PowerShell.Commands.Management/Microsoft.PowerShell.Commands.Management.csproj
43+
- src/Microsoft.PowerShell.Commands.Utility/Microsoft.PowerShell.Commands.Utility.csproj
44+
- src/Microsoft.PowerShell.ConsoleHost/Microsoft.PowerShell.ConsoleHost.csproj
45+
- src/Microsoft.PowerShell.CoreCLR.Eventing/Microsoft.PowerShell.CoreCLR.Eventing.csproj
46+
- src/Microsoft.PowerShell.GlobalTool.Shim/Microsoft.PowerShell.GlobalTool.Shim.csproj
47+
- src/Microsoft.PowerShell.MarkdownRender/Microsoft.PowerShell.MarkdownRender.csproj
48+
- src/Microsoft.PowerShell.SDK/Microsoft.PowerShell.SDK.csproj
49+
- src/Microsoft.PowerShell.Security/Microsoft.PowerShell.Security.csproj
50+
- src/Microsoft.WSMan.Management/Microsoft.WSMan.Management.csproj
51+
- src/Microsoft.WSMan.Runtime/Microsoft.WSMan.Runtime.csproj
52+
- src/Modules/PSGalleryModules.csproj
53+
- src/powershell-win-core/powershell-win-core.csproj
54+
- tools/ci.psm1
55+
- tools/packaging/*
5356

5457
variables:
5558
- name: GIT_CONFIG_PARAMETERS
Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -53,9 +53,9 @@
5353
<!-- Set properties for add/remove programs -->
5454
<Property Id="ARPHELPLINK" Value="$(var.InfoURL)" />
5555
<!-- custom images -->
56-
<WixVariable Id="WixUIBannerBmp" Value="assets\WixUIBannerBmp.png" />
57-
<WixVariable Id="WixUIDialogBmp" Value="assets\WixUIDialogBmp.png" />
58-
<WixVariable Id="WixUIExclamationIco" Value="assets\WixUIInfoIco.png" />
56+
<WixVariable Id="WixUIBannerBmp" Value="assets\wix\WixUIBannerBmp.png" />
57+
<WixVariable Id="WixUIDialogBmp" Value="assets\wix\WixUIDialogBmp.png" />
58+
<WixVariable Id="WixUIExclamationIco" Value="assets\wix\WixUIInfoIco.png" />
5959
<WixVariable Id="WixUIInfoIco" Value="assets\ps_black_32x32.ico" />
6060
<Property Id="WIXUI_EXITDIALOGOPTIONALCHECKBOXTEXT" Value="Open $(var.ProductName)" />
6161
<!-- Default value of Checkbox of starting PowerShell after installation -->
File renamed without changes.

test/powershell/Installer/WindowsInstaller.Tests.ps1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ Describe "Windows Installer" -Tags "Scenario" {
1414
}
1515

1616
It "WiX (Windows Installer XML) file contains pre-requisites link $preRequisitesLink" -Skip:$skipTest {
17-
$wixProductFile = Join-Path -Path $PSScriptRoot -ChildPath "..\..\..\assets\Product.wxs"
17+
$wixProductFile = Join-Path -Path $PSScriptRoot -ChildPath "..\..\..\assets\wix\Product.wxs"
1818
(Get-Content $wixProductFile -Raw).Contains($preRequisitesLink) | Should -BeTrue
1919
}
2020

tools/packaging/packaging.psm1

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2844,7 +2844,7 @@ function New-MSIPatch
28442844
[Parameter(HelpMessage='Path to the patch template WXS. Usually you do not need to specify this')]
28452845
[ValidateNotNullOrEmpty()]
28462846
[ValidateScript( {Test-Path $_})]
2847-
[string] $PatchWxsPath = "$RepoRoot\assets\patch-template.wxs",
2847+
[string] $PatchWxsPath = "$RepoRoot\assets\wix\patch-template.wxs",
28482848

28492849
[Parameter(HelpMessage='Produce a delta patch instead of a full patch. Usually not worth it.')]
28502850
[switch] $Delta
@@ -2884,7 +2884,7 @@ function New-MSIPatch
28842884
Copy-Item -Path $BaselineWixPdbPath -Destination $wixBaselineOriginalPdbPath -Force
28852885
Copy-Item -Path $PatchWixPdbPath -Destination $wixPatchOriginalPdbPath -Force
28862886

2887-
[xml] $filesAssetXml = Get-Content -Raw -Path "$RepoRoot\assets\files.wxs"
2887+
[xml] $filesAssetXml = Get-Content -Raw -Path "$RepoRoot\assets\wix\files.wxs"
28882888
[xml] $patchTemplateXml = Get-Content -Raw -Path $PatchWxsPath
28892889

28902890
# Update the patch version
@@ -2975,12 +2975,12 @@ function New-MSIPackage
29752975
# File describing the MSI Package creation semantics
29762976
[ValidateNotNullOrEmpty()]
29772977
[ValidateScript( {Test-Path $_})]
2978-
[string] $ProductWxsPath = "$RepoRoot\assets\Product.wxs",
2978+
[string] $ProductWxsPath = "$RepoRoot\assets\wix\Product.wxs",
29792979

29802980
# File describing the MSI file components
29812981
[ValidateNotNullOrEmpty()]
29822982
[ValidateScript( {Test-Path $_})]
2983-
[string] $FilesWxsPath = "$RepoRoot\assets\Files.wxs",
2983+
[string] $FilesWxsPath = "$RepoRoot\assets\wix\Files.wxs",
29842984

29852985
# Path to Assets folder containing artifacts such as icons, images
29862986
[ValidateNotNullOrEmpty()]
@@ -3331,7 +3331,7 @@ function Test-FileWxs
33313331
# File describing the MSI file components from the asset folder
33323332
[ValidateNotNullOrEmpty()]
33333333
[ValidateScript( {Test-Path $_})]
3334-
[string] $FilesWxsPath = "$RepoRoot\assets\Files.wxs",
3334+
[string] $FilesWxsPath = "$RepoRoot\assets\wix\Files.wxs",
33353335

33363336
# File describing the MSI file components generated by heat
33373337
[ValidateNotNullOrEmpty()]

0 commit comments

Comments
 (0)