mirror of
https://github.com/actions/setup-node.git
synced 2025-06-29 22:23:47 +00:00
error
This commit is contained in:
parent
01498de30c
commit
50efbd2a86
2 changed files with 9 additions and 7 deletions
|
@ -169,7 +169,8 @@ export default abstract class BaseDistribution {
|
|||
) {
|
||||
return await this.acquireWindowsNodeFromFallbackLocation(
|
||||
info.resolvedVersion,
|
||||
info.arch
|
||||
info.arch,
|
||||
info.downloadUrl
|
||||
);
|
||||
}
|
||||
core.error(`Download failed from ${info.downloadUrl}. Please check the URl and try again.`);
|
||||
|
@ -193,11 +194,12 @@ export default abstract class BaseDistribution {
|
|||
|
||||
protected async acquireWindowsNodeFromFallbackLocation(
|
||||
version: string,
|
||||
arch: string = os.arch()
|
||||
arch: string = os.arch(),
|
||||
downloadUrl : string
|
||||
): Promise<string> {
|
||||
const initialUrl = this.getDistributionUrl();
|
||||
core.info('url: ' + initialUrl);
|
||||
const osArch: string = this.translateArchToDistUrl(arch);
|
||||
const osArch: string = this.translateArchToDistUrl(arch);
|
||||
|
||||
// Create temporary folder to download to
|
||||
const tempDownloadFolder = `temp_${uuidv4()}`;
|
||||
|
@ -212,7 +214,7 @@ export default abstract class BaseDistribution {
|
|||
libUrl = `${initialUrl}/v${version}/win-${osArch}/node.lib`;
|
||||
|
||||
core.info(`Downloading only node binary from ${exeUrl}`);
|
||||
if(!exeUrl ){core.error('unable to download node binary with the provided URL. Please check and try again');}
|
||||
if(downloadUrl != exeUrl ){core.error('unable to download node binary with the provided URL. Please check and try again');}
|
||||
|
||||
|
||||
const exePath = await tc.downloadTool(exeUrl);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue