[Windows] Change .NET SDK pre-installation policy (#4007)

This commit is contained in:
MaksimZhukov
2021-09-06 09:45:16 +03:00
committed by GitHub
parent efc4153250
commit 7546c7f36a

View File

@@ -28,14 +28,9 @@ function Get-SDKVersionsToInstall (
$sdks += $release.'sdks'
}
$sortedSdkVersions = $sdks.version | Sort-Object { [Version] $_ } -Unique
if (Test-IsWin22)
{
return $sortedSdkVersions | Group-Object { $_.Substring(0, $_.LastIndexOf('.') + 2) } | Foreach-Object { $_.Group[-1] }
}
return $sortedSdkVersions
return $sdks.version | Sort-Object { [Version] $_ } -Unique `
| Group-Object { $_.Substring(0, $_.LastIndexOf('.') + 2) } `
| Foreach-Object { $_.Group[-1] }
}
function Invoke-Warmup (