Skip to content

Commit 4a07a7c

Browse files
committed
fix: show message when saving cache
1 parent 746b22c commit 4a07a7c

File tree

3 files changed

+20
-16
lines changed

3 files changed

+20
-16
lines changed

dist/index.js

Lines changed: 10 additions & 8 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/index.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/index.ts

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -258,14 +258,16 @@ function miseDir(): string {
258258
}
259259

260260
async function saveCache(cacheKey: string): Promise<void> {
261-
const cachePath = miseDir()
261+
core.group(`Saving mise cache`, async () => {
262+
const cachePath = miseDir()
262263

263-
if (!fs.existsSync(cachePath)) {
264-
throw new Error(`Cache folder path does not exist on disk: ${cachePath}`)
265-
}
264+
if (!fs.existsSync(cachePath)) {
265+
throw new Error(`Cache folder path does not exist on disk: ${cachePath}`)
266+
}
266267

267-
const cacheId = await cache.saveCache([cachePath], cacheKey)
268-
if (cacheId === -1) return
268+
const cacheId = await cache.saveCache([cachePath], cacheKey)
269+
if (cacheId === -1) return
269270

270-
core.info(`Cache saved from ${cachePath} with key: ${cacheKey}`)
271+
core.info(`Cache saved from ${cachePath} with key: ${cacheKey}`)
272+
})
271273
}

0 commit comments

Comments
 (0)