|
|
@ -49,14 +49,20 @@ async function run() {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
try {
|
|
|
|
try {
|
|
|
|
|
|
|
|
const cacheEntry = await cacheHttpClient.getCacheEntry(keys);
|
|
|
|
|
|
|
|
if (!cacheEntry) {
|
|
|
|
|
|
|
|
core.info(
|
|
|
|
|
|
|
|
`Cache not found for input keys: ${JSON.stringify(keys)}.`
|
|
|
|
|
|
|
|
);
|
|
|
|
|
|
|
|
return;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
let archivePath = path.join(
|
|
|
|
let archivePath = path.join(
|
|
|
|
await utils.createTempDirectory(),
|
|
|
|
await utils.createTempDirectory(),
|
|
|
|
"cache.tgz"
|
|
|
|
"cache.tgz"
|
|
|
|
);
|
|
|
|
);
|
|
|
|
core.debug(`Archive Path: ${archivePath}`);
|
|
|
|
core.debug(`Archive Path: ${archivePath}`);
|
|
|
|
|
|
|
|
|
|
|
|
const cacheEntry = await cacheHttpClient.getCacheEntry(keys);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// Store the cache result
|
|
|
|
// Store the cache result
|
|
|
|
utils.setCacheState(cacheEntry);
|
|
|
|
utils.setCacheState(cacheEntry);
|
|
|
|
|
|
|
|
|
|
|
@ -92,7 +98,7 @@ async function run() {
|
|
|
|
utils.setCacheHitOutput(isExactKeyMatch);
|
|
|
|
utils.setCacheHitOutput(isExactKeyMatch);
|
|
|
|
|
|
|
|
|
|
|
|
core.info(
|
|
|
|
core.info(
|
|
|
|
`Cache restored from key:${cacheEntry && cacheEntry.cacheKey}`
|
|
|
|
`Cache restored from key: ${cacheEntry && cacheEntry.cacheKey}`
|
|
|
|
);
|
|
|
|
);
|
|
|
|
} catch (error) {
|
|
|
|
} catch (error) {
|
|
|
|
core.warning(error.message);
|
|
|
|
core.warning(error.message);
|
|
|
|