File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -66227,9 +66227,8 @@ function restore(id) {
6622766227 if (primaryKey.endsWith('-')) {
6622866228 throw new Error(`No file in ${process.cwd()} matched to [${packageManager.pattern}], make sure you have checked out the target repository`);
6622966229 }
66230- const matchedKey = yield cache.restoreCache(packageManager.path, primaryKey, [
66231- `${CACHE_KEY_PREFIX}-${process.env['RUNNER_OS']}-${id}`
66232- ]);
66230+ // No "restoreKeys" is set, to start with a clear cache after dependency update (see https://github.com/actions/setup-java/issues/269)
66231+ const matchedKey = yield cache.restoreCache(packageManager.path, primaryKey);
6623366232 if (matchedKey) {
6623466233 core.saveState(CACHE_MATCHED_KEY, matchedKey);
6623566234 core.setOutput('cache-hit', matchedKey === primaryKey);
Original file line number Diff line number Diff line change @@ -101432,9 +101432,8 @@ function restore(id) {
101432101432 if (primaryKey.endsWith('-')) {
101433101433 throw new Error(`No file in ${process.cwd()} matched to [${packageManager.pattern}], make sure you have checked out the target repository`);
101434101434 }
101435- const matchedKey = yield cache.restoreCache(packageManager.path, primaryKey, [
101436- `${CACHE_KEY_PREFIX}-${process.env['RUNNER_OS']}-${id}`
101437- ]);
101435+ // No "restoreKeys" is set, to start with a clear cache after dependency update (see https://github.com/actions/setup-java/issues/269)
101436+ const matchedKey = yield cache.restoreCache(packageManager.path, primaryKey);
101438101437 if (matchedKey) {
101439101438 core.saveState(CACHE_MATCHED_KEY, matchedKey);
101440101439 core.setOutput('cache-hit', matchedKey === primaryKey);
Original file line number Diff line number Diff line change @@ -91,9 +91,8 @@ export async function restore(id: string) {
9191 ) ;
9292 }
9393
94- const matchedKey = await cache . restoreCache ( packageManager . path , primaryKey , [
95- `${ CACHE_KEY_PREFIX } -${ process . env [ 'RUNNER_OS' ] } -${ id } `
96- ] ) ;
94+ // No "restoreKeys" is set, to start with a clear cache after dependency update (see https://github.com/actions/setup-java/issues/269)
95+ const matchedKey = await cache . restoreCache ( packageManager . path , primaryKey ) ;
9796 if ( matchedKey ) {
9897 core . saveState ( CACHE_MATCHED_KEY , matchedKey ) ;
9998 core . setOutput ( 'cache-hit' , matchedKey === primaryKey ) ;
You can’t perform that action at this time.
0 commit comments