mirror of
https://github.com/actions/node-versions.git
synced 2025-09-11 23:27:37 +08:00
Compare commits
7 Commits
24.2.0-155
...
LogsPathCh
Author | SHA1 | Date | |
---|---|---|---|
|
e8a6c3090a | ||
|
abceb80206 | ||
|
bebc144061 | ||
|
e2fc36557a | ||
|
7bff9a2a32 | ||
|
ef431e4d6b | ||
|
498365717c |
@@ -8,13 +8,30 @@ Describe "Node.js" {
|
|||||||
function Get-UseNodeLogs {
|
function Get-UseNodeLogs {
|
||||||
# GitHub Windows images don't have `HOME` variable
|
# GitHub Windows images don't have `HOME` variable
|
||||||
$homeDir = $env:HOME ?? $env:HOMEDRIVE
|
$homeDir = $env:HOME ?? $env:HOMEDRIVE
|
||||||
$logsFolderPath = Join-Path -Path $homeDir -ChildPath "runners/*/_diag/pages" -Resolve
|
|
||||||
|
$possiblePaths = @(
|
||||||
$useNodeLogFile = Get-ChildItem -Path $logsFolderPath | Where-Object {
|
Join-Path -Path $homeDir -ChildPath "actions-runner/cached/_diag/pages"
|
||||||
$logContent = Get-Content $_.Fullname -Raw
|
Join-Path -Path $homeDir -ChildPath "runners/*/_diag/pages"
|
||||||
return $logContent -match "setup-node@v"
|
)
|
||||||
} | Select-Object -First 1
|
|
||||||
return $useNodeLogFile.Fullname
|
$logsFolderPath = $possiblePaths | Where-Object { Test-Path $_ } | Select-Object -First 1
|
||||||
|
$resolvedPath = Resolve-Path -Path $logsFolderPath -ErrorAction SilentlyContinue
|
||||||
|
|
||||||
|
if ($resolvedPath -and -not [string]::IsNullOrEmpty($resolvedPath.Path) -and (Test-Path $resolvedPath.Path)) {
|
||||||
|
$useNodeLogFile = Get-ChildItem -Path $resolvedPath | Where-Object {
|
||||||
|
$logContent = Get-Content $_.Fullname -Raw
|
||||||
|
return $logContent -match "setup-node@v"
|
||||||
|
} | Select-Object -First 1
|
||||||
|
|
||||||
|
# Return the file name if a match is found
|
||||||
|
if ($useNodeLogFile) {
|
||||||
|
return $useNodeLogFile.FullName
|
||||||
|
} else {
|
||||||
|
Write-Error "No matching log file found in the specified path: $($resolvedPath.Path)"
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
Write-Error "The provided logs folder path is null, empty, or does not exist: $logsFolderPath"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -1,4 +1,90 @@
|
|||||||
[
|
[
|
||||||
|
{
|
||||||
|
"version": "24.3.0",
|
||||||
|
"stable": true,
|
||||||
|
"release_url": "https://github.com/actions/node-versions/releases/tag/24.3.0-15866716565",
|
||||||
|
"files": [
|
||||||
|
{
|
||||||
|
"filename": "node-24.3.0-darwin-arm64.tar.gz",
|
||||||
|
"arch": "arm64",
|
||||||
|
"platform": "darwin",
|
||||||
|
"download_url": "https://github.com/actions/node-versions/releases/download/24.3.0-15866716565/node-24.3.0-darwin-arm64.tar.gz"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"filename": "node-24.3.0-darwin-x64.tar.gz",
|
||||||
|
"arch": "x64",
|
||||||
|
"platform": "darwin",
|
||||||
|
"download_url": "https://github.com/actions/node-versions/releases/download/24.3.0-15866716565/node-24.3.0-darwin-x64.tar.gz"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"filename": "node-24.3.0-linux-arm64.tar.gz",
|
||||||
|
"arch": "arm64",
|
||||||
|
"platform": "linux",
|
||||||
|
"download_url": "https://github.com/actions/node-versions/releases/download/24.3.0-15866716565/node-24.3.0-linux-arm64.tar.gz"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"filename": "node-24.3.0-linux-x64.tar.gz",
|
||||||
|
"arch": "x64",
|
||||||
|
"platform": "linux",
|
||||||
|
"download_url": "https://github.com/actions/node-versions/releases/download/24.3.0-15866716565/node-24.3.0-linux-x64.tar.gz"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"filename": "node-24.3.0-win32-arm64.7z",
|
||||||
|
"arch": "arm64",
|
||||||
|
"platform": "win32",
|
||||||
|
"download_url": "https://github.com/actions/node-versions/releases/download/24.3.0-15866716565/node-24.3.0-win32-arm64.7z"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"filename": "node-24.3.0-win32-x64.7z",
|
||||||
|
"arch": "x64",
|
||||||
|
"platform": "win32",
|
||||||
|
"download_url": "https://github.com/actions/node-versions/releases/download/24.3.0-15866716565/node-24.3.0-win32-x64.7z"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"version": "24.2.0",
|
||||||
|
"stable": true,
|
||||||
|
"release_url": "https://github.com/actions/node-versions/releases/tag/24.2.0-15549907769",
|
||||||
|
"files": [
|
||||||
|
{
|
||||||
|
"filename": "node-24.2.0-darwin-arm64.tar.gz",
|
||||||
|
"arch": "arm64",
|
||||||
|
"platform": "darwin",
|
||||||
|
"download_url": "https://github.com/actions/node-versions/releases/download/24.2.0-15549907769/node-24.2.0-darwin-arm64.tar.gz"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"filename": "node-24.2.0-darwin-x64.tar.gz",
|
||||||
|
"arch": "x64",
|
||||||
|
"platform": "darwin",
|
||||||
|
"download_url": "https://github.com/actions/node-versions/releases/download/24.2.0-15549907769/node-24.2.0-darwin-x64.tar.gz"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"filename": "node-24.2.0-linux-arm64.tar.gz",
|
||||||
|
"arch": "arm64",
|
||||||
|
"platform": "linux",
|
||||||
|
"download_url": "https://github.com/actions/node-versions/releases/download/24.2.0-15549907769/node-24.2.0-linux-arm64.tar.gz"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"filename": "node-24.2.0-linux-x64.tar.gz",
|
||||||
|
"arch": "x64",
|
||||||
|
"platform": "linux",
|
||||||
|
"download_url": "https://github.com/actions/node-versions/releases/download/24.2.0-15549907769/node-24.2.0-linux-x64.tar.gz"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"filename": "node-24.2.0-win32-arm64.7z",
|
||||||
|
"arch": "arm64",
|
||||||
|
"platform": "win32",
|
||||||
|
"download_url": "https://github.com/actions/node-versions/releases/download/24.2.0-15549907769/node-24.2.0-win32-arm64.7z"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"filename": "node-24.2.0-win32-x64.7z",
|
||||||
|
"arch": "x64",
|
||||||
|
"platform": "win32",
|
||||||
|
"download_url": "https://github.com/actions/node-versions/releases/download/24.2.0-15549907769/node-24.2.0-win32-x64.7z"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"version": "24.1.0",
|
"version": "24.1.0",
|
||||||
"stable": true,
|
"stable": true,
|
||||||
@@ -171,6 +257,50 @@
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"version": "22.17.0",
|
||||||
|
"stable": true,
|
||||||
|
"lts": "Jod",
|
||||||
|
"release_url": "https://github.com/actions/node-versions/releases/tag/22.17.0-15866718879",
|
||||||
|
"files": [
|
||||||
|
{
|
||||||
|
"filename": "node-22.17.0-darwin-arm64.tar.gz",
|
||||||
|
"arch": "arm64",
|
||||||
|
"platform": "darwin",
|
||||||
|
"download_url": "https://github.com/actions/node-versions/releases/download/22.17.0-15866718879/node-22.17.0-darwin-arm64.tar.gz"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"filename": "node-22.17.0-darwin-x64.tar.gz",
|
||||||
|
"arch": "x64",
|
||||||
|
"platform": "darwin",
|
||||||
|
"download_url": "https://github.com/actions/node-versions/releases/download/22.17.0-15866718879/node-22.17.0-darwin-x64.tar.gz"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"filename": "node-22.17.0-linux-arm64.tar.gz",
|
||||||
|
"arch": "arm64",
|
||||||
|
"platform": "linux",
|
||||||
|
"download_url": "https://github.com/actions/node-versions/releases/download/22.17.0-15866718879/node-22.17.0-linux-arm64.tar.gz"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"filename": "node-22.17.0-linux-x64.tar.gz",
|
||||||
|
"arch": "x64",
|
||||||
|
"platform": "linux",
|
||||||
|
"download_url": "https://github.com/actions/node-versions/releases/download/22.17.0-15866718879/node-22.17.0-linux-x64.tar.gz"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"filename": "node-22.17.0-win32-arm64.7z",
|
||||||
|
"arch": "arm64",
|
||||||
|
"platform": "win32",
|
||||||
|
"download_url": "https://github.com/actions/node-versions/releases/download/22.17.0-15866718879/node-22.17.0-win32-arm64.7z"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"filename": "node-22.17.0-win32-x64.7z",
|
||||||
|
"arch": "x64",
|
||||||
|
"platform": "win32",
|
||||||
|
"download_url": "https://github.com/actions/node-versions/releases/download/22.17.0-15866718879/node-22.17.0-win32-x64.7z"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"version": "22.16.0",
|
"version": "22.16.0",
|
||||||
"stable": true,
|
"stable": true,
|
||||||
@@ -1095,6 +1225,50 @@
|
|||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"version": "20.19.3",
|
||||||
|
"stable": true,
|
||||||
|
"lts": "Iron",
|
||||||
|
"release_url": "https://github.com/actions/node-versions/releases/tag/20.19.3-15828158811",
|
||||||
|
"files": [
|
||||||
|
{
|
||||||
|
"filename": "node-20.19.3-darwin-arm64.tar.gz",
|
||||||
|
"arch": "arm64",
|
||||||
|
"platform": "darwin",
|
||||||
|
"download_url": "https://github.com/actions/node-versions/releases/download/20.19.3-15828158811/node-20.19.3-darwin-arm64.tar.gz"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"filename": "node-20.19.3-darwin-x64.tar.gz",
|
||||||
|
"arch": "x64",
|
||||||
|
"platform": "darwin",
|
||||||
|
"download_url": "https://github.com/actions/node-versions/releases/download/20.19.3-15828158811/node-20.19.3-darwin-x64.tar.gz"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"filename": "node-20.19.3-linux-arm64.tar.gz",
|
||||||
|
"arch": "arm64",
|
||||||
|
"platform": "linux",
|
||||||
|
"download_url": "https://github.com/actions/node-versions/releases/download/20.19.3-15828158811/node-20.19.3-linux-arm64.tar.gz"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"filename": "node-20.19.3-linux-x64.tar.gz",
|
||||||
|
"arch": "x64",
|
||||||
|
"platform": "linux",
|
||||||
|
"download_url": "https://github.com/actions/node-versions/releases/download/20.19.3-15828158811/node-20.19.3-linux-x64.tar.gz"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"filename": "node-20.19.3-win32-arm64.7z",
|
||||||
|
"arch": "arm64",
|
||||||
|
"platform": "win32",
|
||||||
|
"download_url": "https://github.com/actions/node-versions/releases/download/20.19.3-15828158811/node-20.19.3-win32-arm64.7z"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"filename": "node-20.19.3-win32-x64.7z",
|
||||||
|
"arch": "x64",
|
||||||
|
"platform": "win32",
|
||||||
|
"download_url": "https://github.com/actions/node-versions/releases/download/20.19.3-15828158811/node-20.19.3-win32-x64.7z"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"version": "20.19.2",
|
"version": "20.19.2",
|
||||||
"stable": true,
|
"stable": true,
|
||||||
|
Reference in New Issue
Block a user