From f4b7bb66b591e3a49c24d9632bc1c2bad8b62cc5 Mon Sep 17 00:00:00 2001 From: Danny McCormick Date: Mon, 5 Aug 2019 21:48:23 -0400 Subject: [PATCH] Update installer.ts --- src/installer.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/installer.ts b/src/installer.ts index 1697cd4c..7433ff3c 100644 --- a/src/installer.ts +++ b/src/installer.ts @@ -214,18 +214,18 @@ async function acquireNodeFromFallbackLocation( libUrl = `https://nodejs.org/dist/v${version}/win-${os.arch()}/node.lib`; const exePath = await tc.downloadTool(exeUrl); - await io.mv(exePath, path.join(tempDir, 'node.exe')); + await io.cp(exePath, path.join(tempDir, 'node.exe')); const libPath = await tc.downloadTool(libUrl); - await io.mv(libPath, path.join(tempDir, 'node.lib')); + await io.cp(libPath, path.join(tempDir, 'node.lib')); } catch (err) { if (err instanceof tc.HTTPError && err.httpStatusCode == 404) { exeUrl = `https://nodejs.org/dist/v${version}/node.exe`; libUrl = `https://nodejs.org/dist/v${version}/node.lib`; const exePath = await tc.downloadTool(exeUrl); - await io.mv(exePath, path.join(tempDir, 'node.exe')); + await io.cp(exePath, path.join(tempDir, 'node.exe')); const libPath = await tc.downloadTool(libUrl); - await io.mv(libPath, path.join(tempDir, 'node.lib')); + await io.cp(libPath, path.join(tempDir, 'node.lib')); } else { throw err; }