1
0
Fork 0
mirror of https://github.com/actions/setup-go synced 2024-12-22 06:12:42 +00:00

Merge pull request #141 from paulcacheux/fix-windows-extractor-selection

Fix extractor selection on windows
This commit is contained in:
Josh Gross 2021-08-25 11:43:04 -04:00 committed by GitHub
commit 331ce1d993
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 4 deletions

4
dist/index.js vendored
View file

@ -5084,9 +5084,9 @@ function installGoVersion(info, auth) {
}
function extractGoArchive(archivePath) {
return __awaiter(this, void 0, void 0, function* () {
const arch = os_1.default.arch();
const platform = os_1.default.platform();
let extPath;
if (arch === 'win32') {
if (platform === 'win32') {
extPath = yield tc.extractZip(archivePath);
}
else {

View file

@ -122,10 +122,10 @@ async function installGoVersion(
}
export async function extractGoArchive(archivePath: string): Promise<string> {
const arch = os.arch();
const platform = os.platform();
let extPath: string;
if (arch === 'win32') {
if (platform === 'win32') {
extPath = await tc.extractZip(archivePath);
} else {
extPath = await tc.extractTar(archivePath);