mirror of
https://code.forgejo.org/actions/setup-node.git
synced 2025-05-19 21:04:45 +00:00
Revert "Temporarily disable image cache usage for v1"
This commit is contained in:
parent
eb416799cf
commit
108628bcbd
3 changed files with 6 additions and 14 deletions
7
dist/index.js
vendored
7
dist/index.js
vendored
|
@ -12231,8 +12231,7 @@ function getNode(versionSpec) {
|
|||
let toolPath;
|
||||
toolPath = tc.find('node', versionSpec);
|
||||
// If not found in cache, download
|
||||
// Usage of pre-cached Node.js is temporarily disabled.
|
||||
if (true) {
|
||||
if (!toolPath) {
|
||||
let version;
|
||||
const c = semver.clean(versionSpec) || '';
|
||||
// If explicit version
|
||||
|
@ -12249,8 +12248,7 @@ function getNode(versionSpec) {
|
|||
// check cache
|
||||
toolPath = tc.find('node', version);
|
||||
}
|
||||
// Usage of pre-cached Node.js is temporarily disabled.
|
||||
if (true) {
|
||||
if (!toolPath) {
|
||||
// download, extract, cache
|
||||
toolPath = yield acquireNode(version);
|
||||
}
|
||||
|
@ -12344,7 +12342,6 @@ function acquireNode(version) {
|
|||
let downloadUrl = `https://nodejs.org/dist/v${version}/${urlFileName}`;
|
||||
let downloadPath;
|
||||
try {
|
||||
core.info(`Downloading ${downloadUrl}`);
|
||||
downloadPath = yield tc.downloadTool(downloadUrl);
|
||||
}
|
||||
catch (err) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue