Skip to content

Commit b48e1df

Browse files
authored
feat: log when restoring from cache (#152)
* feat: log when restoring from cache * undo semicolon change
1 parent 855ae7a commit b48e1df

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

src/run.ts

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
// Copyright (c) Microsoft Corporation.
2-
// Copyright (c) Microsoft Corporation.
32
// Licensed under the MIT license.
43

54
import * as os from 'os'
@@ -26,7 +25,7 @@ export async function run() {
2625

2726
const downloadBaseURL = core.getInput('downloadBaseURL', {required: false})
2827

29-
core.startGroup(`Downloading ${version}`)
28+
core.startGroup(`Installing ${version}`)
3029
const cachedPath = await downloadHelm(downloadBaseURL, version)
3130
core.endGroup()
3231

@@ -88,7 +87,10 @@ export async function downloadHelm(
8887
version: string
8988
): Promise<string> {
9089
let cachedToolpath = toolCache.find(helmToolName, version)
91-
if (!cachedToolpath) {
90+
if (cachedToolpath) {
91+
core.info(`Restoring '${version}' from cache`)
92+
} else {
93+
core.info(`Downloading '${version}' from '${baseURL}'`)
9294
let helmDownloadPath
9395
try {
9496
helmDownloadPath = await toolCache.downloadTool(

0 commit comments

Comments
 (0)