mirror of
https://github.com/goreleaser/goreleaser-action
synced 2026-07-09 19:37:31 +00:00
improve install
This commit is contained in:
+5
-4
@@ -29,11 +29,12 @@ export async function install(distribution: string, version: string): Promise<st
|
|||||||
let extPath: string;
|
let extPath: string;
|
||||||
if (context.osPlat == 'win32') {
|
if (context.osPlat == 'win32') {
|
||||||
if(!downloadPath.endsWith('.zip')) {
|
if(!downloadPath.endsWith('.zip')) {
|
||||||
let newPath = downloadPath + '.zip'
|
let newPath = downloadPath + '.zip';
|
||||||
fs.renameSync(downloadPath, newPath)
|
fs.renameSync(downloadPath, newPath);
|
||||||
downloadPath = newPath
|
extPath = await tc.extractZip(newPath);
|
||||||
|
} else {
|
||||||
|
extPath = await tc.extractZip(downloadPath);
|
||||||
}
|
}
|
||||||
extPath = await tc.extractZip(downloadPath);
|
|
||||||
} else {
|
} else {
|
||||||
extPath = await tc.extractTar(downloadPath);
|
extPath = await tc.extractTar(downloadPath);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user