[InternalCI.ps1] Fix error when buildtrees/ does not exist

This commit is contained in:
Alexander Karatarakis 2017-10-24 17:08:24 -07:00
parent 23702360ce
commit aec9215800

View File

@ -5,7 +5,10 @@ New-Item -type directory downloads -errorAction SilentlyContinue | Out-Null
if (-not $?) { throw $? }
# Clear out any intermediate files from the previous build
Get-ChildItem buildtrees/*/* | ? { $_.Name -ne "src" -and $_.Extension -ne ".log"} | Remove-Item -Recurse -Force
if (Test-Path buildtrees)
{
Get-ChildItem buildtrees/*/* | ? { $_.Name -ne "src" -and $_.Extension -ne ".log"} | Remove-Item -Recurse -Force
}
# Purge any outdated packages
./vcpkg remove --outdated --recurse