mirror of
https://github.com/actions/runner-images.git
synced 2025-12-14 05:07:02 +00:00
rework ruby installation
This commit is contained in:
@@ -286,12 +286,6 @@ function Get-VSExtensionVersion
|
||||
return $packageVersion
|
||||
}
|
||||
|
||||
function Get-ToolcachePackages
|
||||
{
|
||||
$toolcachePath = Join-Path $env:ROOT_FOLDER "toolcache.json"
|
||||
Get-Content -Raw $toolcachePath | ConvertFrom-Json
|
||||
}
|
||||
|
||||
function Get-ToolsetContent
|
||||
{
|
||||
$toolsetJson = Get-Content -Path $env:TOOLSET_JSON_PATH -Raw
|
||||
@@ -350,24 +344,6 @@ function Get-ToolsetToolFullPath
|
||||
return Join-Path $foundVersion $Arch
|
||||
}
|
||||
|
||||
function Get-ToolsByName
|
||||
{
|
||||
Param
|
||||
(
|
||||
[Parameter(Mandatory = $True)]
|
||||
[string]$SoftwareName
|
||||
)
|
||||
|
||||
(Get-ToolcachePackages).PSObject.Properties | Where-Object { $_.Name -match $SoftwareName } | ForEach-Object {
|
||||
$packageNameParts = $_.Name.Split("-")
|
||||
[PSCustomObject] @{
|
||||
ToolName = $packageNameParts[1]
|
||||
Versions = $_.Value
|
||||
Architecture = $packageNameParts[3,4] -join "-"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function Get-WinVersion
|
||||
{
|
||||
(Get-CimInstance -ClassName Win32_OperatingSystem).Caption
|
||||
|
||||
Reference in New Issue
Block a user