Skip to content

Commit

Permalink
downgrade log message for archive extraction
Browse files Browse the repository at this point in the history
fixes #41
  • Loading branch information
jaxxstorm committed Mar 13, 2023
1 parent 32cdb7d commit 41f5dfd
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 14 deletions.
26 changes: 13 additions & 13 deletions lib/main.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,11 @@
"use strict";
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
if (k2 === undefined) k2 = k;
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
var desc = Object.getOwnPropertyDescriptor(m, k);
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
desc = { enumerable: true, get: function() { return m[k]; } };
}
Object.defineProperty(o, k2, desc);
}) : (function(o, m, k, k2) {
if (k2 === undefined) k2 = k;
o[k2] = m[k];
Expand All @@ -14,7 +18,7 @@ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (
var __importStar = (this && this.__importStar) || function (mod) {
if (mod && mod.__esModule) return mod;
var result = {};
if (mod != null) for (var k in mod) if (k !== "default" && Object.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
__setModuleDefault(result, mod);
return result;
};
Expand Down Expand Up @@ -53,15 +57,13 @@ function run() {
core.info(`Retrying after ${retryAfter} seconds.`);
return true;
},
} }, utils_1.getOctokitOptions(token)));
} }, (0, utils_1.getOctokitOptions)(token)));
const repo = core.getInput("repo");
if (!repo) {
throw new Error(`Repo was not specified`);
}
const tag = core.getInput("tag");
if (!tag) {
throw new Error(`Tag not specified`);
}
let tag = core.getInput("tag");
tag = !tag ? "latest" : tag;
const cacheEnabled = (core.getInput("cache") === "enable")
&& tag !== "latest"
&& tag !== "";
Expand Down Expand Up @@ -139,12 +141,10 @@ function run() {
osArch: osArch,
osPlatform: osPlatform
};
// first candidate folder where to find the binaries
// after downloading the release
let dest = toolPath(toolInfo);
// If the user has specified a custom bin location, it means
// that the archive contains a folder with the binaries.
// In this case, we need to use that folder and add it to the path.
// If the user has specified a custom location where the binaries are in the release
// asset, we need to use modify the default path, joining the custom folder to the
// default path.
let binariesLocation = core.getInput("binaries-location");
let finalBinLocation = dest;
if (binariesLocation !== "") {
Expand Down Expand Up @@ -232,7 +232,7 @@ function run() {
// parameter then this is where we apply those.
// Regardless of any rename-to parameter we still need to move the download to the actual destination
// otherwise it won't end up on the path as expected
core.warning(`Release asset ${asset.name} did not have a recognised file extension, unable to automatically extract it`);
core.info(`Release asset ${asset.name} did not have a recognised file extension, unable to automatically extract it`);
try {
fs.mkdirSync(dest, { 'recursive': true });
const outputPath = path.join(dest, renameTo !== "" ? renameTo : path.basename(binPath));
Expand Down
2 changes: 1 addition & 1 deletion src/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -236,7 +236,7 @@ async function run() {
// parameter then this is where we apply those.
// Regardless of any rename-to parameter we still need to move the download to the actual destination
// otherwise it won't end up on the path as expected
core.warning(
core.info(
`Release asset ${asset.name} did not have a recognised file extension, unable to automatically extract it`)
try {
fs.mkdirSync(dest, { 'recursive': true });
Expand Down

0 comments on commit 41f5dfd

Please sign in to comment.