Remove WiX install (#16834)

This commit is contained in:
Travis Plunk
2022-02-02 15:20:41 -08:00
committed by GitHub
parent e840db81ab
commit b7f8556bcd
2 changed files with 8 additions and 31 deletions
@@ -177,7 +177,8 @@ stages:
- deployment: AzureBlobPublic
displayName: Make Azure Blob Public
pool: PowerShell1ES
pool:
name: PowerShell1ES
demands:
- ImageOverride -equals PSMMS2019-Secure
@@ -42,7 +42,7 @@ jobs:
- template: shouldSign.yml
- powershell: |
- pwsh: |
$pkgFilter = if ( '$(Architecture)' -eq 'arm' ) { "arm32" } else { '$(Architecture)' }
if ($env:BuildConfiguration -eq 'minSize') { $pkgFilter += '-gc' }
@@ -60,25 +60,6 @@ jobs:
- template: cloneToOfficialPath.yml
- pwsh: |
# cleanup previous install
if((Test-Path "${env:ProgramFiles(x86)}\WiX Toolset xcopy")) {
Remove-Item "${env:ProgramFiles(x86)}\WiX Toolset xcopy" -Recurse -Force
}
$toolsDir = New-Item -ItemType Directory -Path '$(Build.ArtifactStagingDirectory)\tools'
$wixUri = 'https://github.com/wixtoolset/wix3/releases/download/wix3112rtm/wix311-binaries.zip'
Invoke-RestMethod -Uri $wixUri -OutFile '$(Build.ArtifactStagingDirectory)\tools\wix.zip' -MaximumRetryCount 5 -RetryIntervalSec 10
Import-Module '$(PowerShellRoot)/tools/releaseBuild/Images/microsoft_powershell_windowsservercore/wix.psm1'
Install-WixZip -zipPath '$(Build.ArtifactStagingDirectory)\tools\wix.zip'
$msixUrl = '$(makeappUrl)'
Invoke-RestMethod -Uri $msixUrl -OutFile '\makeappx.zip'
Expand-Archive '\makeappx.zip' -destination '\' -Force
displayName: Install packaging tools
- powershell: |
$zipPathString = '$(System.ArtifactsDirectory)\Symbols\results\*$(PkgFilter).zip'
Write-Verbose -Verbose "Zip Path: $zipPathString"
$zipPath = Get-Item $zipPathString
@@ -208,12 +189,12 @@ jobs:
shouldSign: $(SHOULD_SIGN)
displayName: Sign ThirdParty binaries
- powershell: |
- pwsh: |
Get-ChildItem '$(System.ArtifactsDirectory)\thirdPartySigned\*'
displayName: Capture ThirdParty Signed files
condition: and(succeeded(), eq(variables['SHOULD_SIGN'], 'true'))
- powershell: |
- pwsh: |
Import-Module $(PowerShellRoot)/build.psm1 -Force
Import-Module $(PowerShellRoot)/tools/packaging -Force
$signedFilesPath = '$(System.ArtifactsDirectory)\thirdPartySigned'
@@ -231,7 +212,7 @@ jobs:
PackageVersion: $(Version)
sourceScanPath: '$(PowerShellRoot)\tools'
- powershell: |
- pwsh: |
Import-Module $(PowerShellRoot)/build.psm1 -Force
Import-Module $(PowerShellRoot)/tools/packaging -Force
@@ -272,7 +253,7 @@ jobs:
$(PowerShellRoot)/tools/releaseBuild/Images/microsoft_powershell_windowsservercore/PowerShellPackage.ps1 -BuildZip $signedPkg -location '$(PowerShellRoot)' -destination '$(System.ArtifactsDirectory)\pkgSigned' -Runtime $runtime -ReleaseTag '$(ReleaseTagVar)' @params
displayName: 'Build Windows Universal - $(Architecture) Package'
- powershell: |
- pwsh: |
Get-ChildItem '$(System.ArtifactsDirectory)\pkgSigned' | ForEach-Object {
$packagePath = $_.FullName
Write-Host "Uploading $packagePath"
@@ -363,17 +344,12 @@ jobs:
sourceScanPath: '$(PowerShellRoot)\tools'
snapshotForceEnabled: true
- powershell: |
- pwsh: |
if ((Test-Path "\PowerShell")) {
Remove-Item -Path "\PowerShell" -Force -Recurse -Verbose
}
else {
Write-Verbose -Verbose -Message "No cleanup required."
}
if((Test-Path "${env:ProgramFiles(x86)}\WiX Toolset xcopy")) {
Write-Verbose -Verbose "Cleaning up Wix tools"
Remove-Item "${env:ProgramFiles(x86)}\WiX Toolset xcopy" -Recurse -Force
}
displayName: Clean up local Clone
condition: always()