mirror of
https://github.com/PowerShell/PowerShell
synced 2026-06-08 12:12:50 +00:00
Revert "Fetch latest ICU release version dynamically" (#27127)
This commit is contained in:
@@ -2152,7 +2152,7 @@ function Get-PackageDependencies
|
||||
# than the build version and we know that older versions just works.
|
||||
#
|
||||
$MinICUVersion = 60 # runtime minimum supported
|
||||
$BuildICUVersion = Get-IcuLatestRelease
|
||||
$BuildICUVersion = 76 # current build version
|
||||
$MaxICUVersion = $BuildICUVersion + 30 # headroom
|
||||
|
||||
if ($Distribution -eq 'deb') {
|
||||
@@ -5809,15 +5809,3 @@ function Test-IsProductFile {
|
||||
|
||||
return $false
|
||||
}
|
||||
|
||||
# Get major version from latest ICU release (latest: stable version)
|
||||
function Get-IcuLatestRelease {
|
||||
$response = Invoke-WebRequest -Uri "https://github.com/unicode-org/icu/releases/latest"
|
||||
$tagUrl = ($response.Links | Where-Object href -like "*releases/tag/release-*")[0].href
|
||||
|
||||
if ($tagUrl -match 'release-(\d+)\.') {
|
||||
return [int]$Matches[1]
|
||||
}
|
||||
|
||||
throw "Unable to determine the latest ICU release version."
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user