mirror of
https://github.com/actions/setup-node.git
synced 2025-06-29 22:23:47 +00:00
check-latest
This commit is contained in:
parent
6285145ddd
commit
a7b5311f2b
4 changed files with 12 additions and 3 deletions
|
@ -318,6 +318,11 @@ export default class OfficialBuilds extends BaseDistribution {
|
|||
const versions = this.filterVersions(nodeJsVersions);
|
||||
const evaluatedVersion = this.evaluateVersions(versions);
|
||||
|
||||
if (this.nodeInfo.checkLatest) {
|
||||
const evaluatedVersion = await this.findVersionInDist(nodeJsVersions);
|
||||
this.nodeInfo.versionSpec = evaluatedVersion;
|
||||
}
|
||||
|
||||
if (!evaluatedVersion) {
|
||||
throw new Error(
|
||||
`Unable to find Node version '${this.nodeInfo.versionSpec}' for platform ${this.osPlat} and architecture ${this.nodeInfo.arch}.`
|
||||
|
|
|
@ -33,7 +33,7 @@ export async function run() {
|
|||
arch = os.arch();
|
||||
}
|
||||
|
||||
const mirrorURL = core.getInput('mirrorURL').trim(); // .trim() to remove any accidental spaces
|
||||
const mirrorURL = core.getInput('mirror-url').trim(); // .trim() to remove any accidental spaces
|
||||
|
||||
|
||||
if (version) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue