src: Rename showVersion()
This commit is contained in:
parent
876c3e1bbf
commit
2b2ecc2dd1
1 changed files with 3 additions and 4 deletions
|
|
@ -5,8 +5,7 @@ import installer from './installer';
|
||||||
|
|
||||||
// most @actions toolkit packages have async methods
|
// most @actions toolkit packages have async methods
|
||||||
async function run() {
|
async function run() {
|
||||||
const dump = async () => {
|
const showVersion = async () => {
|
||||||
// Show version
|
|
||||||
await exec.exec('hugo version');
|
await exec.exec('hugo version');
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
@ -18,7 +17,7 @@ async function run() {
|
||||||
async function(latestVersion): Promise<void> {
|
async function(latestVersion): Promise<void> {
|
||||||
console.log(`Hugo version: ${latestVersion} (${hugoVersion})`);
|
console.log(`Hugo version: ${latestVersion} (${hugoVersion})`);
|
||||||
await installer(latestVersion);
|
await installer(latestVersion);
|
||||||
await dump();
|
await showVersion();
|
||||||
},
|
},
|
||||||
function(error) {
|
function(error) {
|
||||||
core.setFailed(error);
|
core.setFailed(error);
|
||||||
|
|
@ -27,7 +26,7 @@ async function run() {
|
||||||
} else {
|
} else {
|
||||||
console.log(`Hugo version: ${hugoVersion}`);
|
console.log(`Hugo version: ${hugoVersion}`);
|
||||||
await installer(hugoVersion);
|
await installer(hugoVersion);
|
||||||
await dump();
|
await showVersion();
|
||||||
}
|
}
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
core.setFailed(error.message);
|
core.setFailed(error.message);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue