diff --git a/src/cache-restore.ts b/src/cache-restore.ts index 7f761da4..a1b46233 100644 --- a/src/cache-restore.ts +++ b/src/cache-restore.ts @@ -37,11 +37,13 @@ export const restoreCache = async ( } const primaryKey = `node-cache-${platform}-${packageManager}-${fileHash}`; + const restoreKeys = [`node-cache-${platform}-${packageManager}-`]; core.debug(`primary key is ${primaryKey}`); + core.debug(`restore keys are [${restoreKeys}]`); core.saveState(State.CachePrimaryKey, primaryKey); - const cacheKey = await cache.restoreCache([cachePath], primaryKey); + const cacheKey = await cache.restoreCache([cachePath], primaryKey, restoreKeys); core.setOutput('cache-hit', Boolean(cacheKey)); if (!cacheKey) {