mirror of
https://github.com/actions/setup-node.git
synced 2025-04-22 09:21:00 +00:00
fix readme and warning
This commit is contained in:
parent
1405bc86d4
commit
dbbe0bac60
3 changed files with 5 additions and 4 deletions
|
@ -41,8 +41,9 @@ steps:
|
||||||
- run: npm test
|
- run: npm test
|
||||||
```
|
```
|
||||||
|
|
||||||
Checking latest version of Node.js:
|
Check latest version:
|
||||||
(By default, action searches version locally before downloading it. The flag forces action to check if cached version is not outdated)
|
> In basic example, without `check-latest` flag, the action tries to resolve version from local cache firstly and download only if it is not found. Local cache on image is updated with a couple of weeks latency.
|
||||||
|
`check-latest` flag forces the action to check if the cached version is the latest one. It reduces latency significantly but it is much more likely to incur version downloading.
|
||||||
```yaml
|
```yaml
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v2
|
||||||
|
|
2
dist/index.js
vendored
2
dist/index.js
vendored
|
@ -13153,7 +13153,7 @@ function resolveVersionFromManifest(versionSpec, stable, auth) {
|
||||||
return info === null || info === void 0 ? void 0 : info.resolvedVersion;
|
return info === null || info === void 0 ? void 0 : info.resolvedVersion;
|
||||||
}
|
}
|
||||||
catch (err) {
|
catch (err) {
|
||||||
core.warning('Unable to resolve version from manifest...');
|
core.info('Unable to resolve version from manifest...');
|
||||||
core.debug(err.message);
|
core.debug(err.message);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
|
@ -219,7 +219,7 @@ async function resolveVersionFromManifest(
|
||||||
const info = await getInfoFromManifest(versionSpec, stable, auth);
|
const info = await getInfoFromManifest(versionSpec, stable, auth);
|
||||||
return info?.resolvedVersion;
|
return info?.resolvedVersion;
|
||||||
} catch (err) {
|
} catch (err) {
|
||||||
core.warning('Unable to resolve version from manifest...');
|
core.info('Unable to resolve version from manifest...');
|
||||||
core.debug(err.message);
|
core.debug(err.message);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue