This commit is contained in:
Heng Lu 2022-02-22 13:33:31 +08:00
Родитель 1dd8691974
Коммит 2c137b63d6
1 изменённых файлов: 3 добавлений и 2 удалений

Просмотреть файл

@ -111,8 +111,9 @@ async function run(platform: string, architecture: string) {
}); });
// unzip // unzip
const versionedName = path.resolve(installPath, `azurerm-restapi-lsp_${release.version}.exe`); const fileExtension = os === "windows" ? ".exe" : "";
const unversionedName = path.resolve(installPath, `azurerm-restapi-lsp.exe`); const versionedName = path.resolve(installPath, `azurerm-restapi-lsp_${release.version}${fileExtension}`);
const unversionedName = path.resolve(installPath, `azurerm-restapi-lsp${fileExtension}`);
const fileReadStream = fs.createReadStream(zipfile); const fileReadStream = fs.createReadStream(zipfile);
const unzipPipe = unzip.Extract({ path: installPath }); const unzipPipe = unzip.Extract({ path: installPath });
fileReadStream.pipe(unzipPipe); fileReadStream.pipe(unzipPipe);