Skip to content

Commit

Permalink
Merge pull request #141 from paulcacheux/fix-windows-extractor-selection
Browse files Browse the repository at this point in the history
Fix extractor selection on windows
  • Loading branch information
joshmgross authored Aug 25, 2021
2 parents 1087a81 + bba6fe1 commit 331ce1d
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions dist/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -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 {
Expand Down
4 changes: 2 additions & 2 deletions src/installer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -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);
Expand Down

0 comments on commit 331ce1d

Please sign in to comment.