|
|
@ -18,9 +18,16 @@ export const restoreCache = async (
|
|
|
|
|
|
|
|
|
|
|
|
const cachePaths = await getCacheDirectoryPath(packageManagerInfo);
|
|
|
|
const cachePaths = await getCacheDirectoryPath(packageManagerInfo);
|
|
|
|
|
|
|
|
|
|
|
|
const dependencyFilePath = cacheDependencyPath
|
|
|
|
let dependencyFilePath: string
|
|
|
|
|
|
|
|
try {
|
|
|
|
|
|
|
|
dependencyFilePath = cacheDependencyPath
|
|
|
|
? cacheDependencyPath
|
|
|
|
? cacheDependencyPath
|
|
|
|
: findDependencyFile(packageManagerInfo);
|
|
|
|
: findDependencyFile(packageManagerInfo);
|
|
|
|
|
|
|
|
} catch (e) {
|
|
|
|
|
|
|
|
core.info(e);
|
|
|
|
|
|
|
|
core.setOutput(Outputs.CacheHit, false);
|
|
|
|
|
|
|
|
return;
|
|
|
|
|
|
|
|
}
|
|
|
|
const fileHash = await glob.hashFiles(dependencyFilePath);
|
|
|
|
const fileHash = await glob.hashFiles(dependencyFilePath);
|
|
|
|
|
|
|
|
|
|
|
|
if (!fileHash) {
|
|
|
|
if (!fileHash) {
|
|
|
|