File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -61868,9 +61868,8 @@ function restore(id) {
6186861868 if (primaryKey.endsWith('-')) {
6186961869 throw new Error(`No file in ${process.cwd()} matched to [${packageManager.pattern}], make sure you have checked out the target repository`);
6187061870 }
61871- const matchedKey = yield cache.restoreCache(packageManager.path, primaryKey, [
61872- `${CACHE_KEY_PREFIX}-${process.env['RUNNER_OS']}-${id}`
61873- ]);
61871+ // No "restoreKeys" is set, to start with a clear cache after dependency update (see https://github.com/actions/setup-java/issues/269)
61872+ const matchedKey = yield cache.restoreCache(packageManager.path, primaryKey);
6187461873 if (matchedKey) {
6187561874 core.saveState(CACHE_MATCHED_KEY, matchedKey);
6187661875 core.info(`Cache restored from key: ${matchedKey}`);
Original file line number Diff line number Diff line change @@ -18659,9 +18659,8 @@ function restore(id) {
1865918659 if (primaryKey.endsWith('-')) {
1866018660 throw new Error(`No file in ${process.cwd()} matched to [${packageManager.pattern}], make sure you have checked out the target repository`);
1866118661 }
18662- const matchedKey = yield cache.restoreCache(packageManager.path, primaryKey, [
18663- `${CACHE_KEY_PREFIX}-${process.env['RUNNER_OS']}-${id}`
18664- ]);
18662+ // No "restoreKeys" is set, to start with a clear cache after dependency update (see https://github.com/actions/setup-java/issues/269)
18663+ const matchedKey = yield cache.restoreCache(packageManager.path, primaryKey);
1866518664 if (matchedKey) {
1866618665 core.saveState(CACHE_MATCHED_KEY, matchedKey);
1866718666 core.info(`Cache restored from key: ${matchedKey}`);
Original file line number Diff line number Diff line change @@ -72,9 +72,8 @@ export async function restore(id: string) {
7272 ) ;
7373 }
7474
75- const matchedKey = await cache . restoreCache ( packageManager . path , primaryKey , [
76- `${ CACHE_KEY_PREFIX } -${ process . env [ 'RUNNER_OS' ] } -${ id } `
77- ] ) ;
75+ // No "restoreKeys" is set, to start with a clear cache after dependency update (see https://github.com/actions/setup-java/issues/269)
76+ const matchedKey = await cache . restoreCache ( packageManager . path , primaryKey ) ;
7877 if ( matchedKey ) {
7978 core . saveState ( CACHE_MATCHED_KEY , matchedKey ) ;
8079 core . info ( `Cache restored from key: ${ matchedKey } ` ) ;
You can’t perform that action at this time.
0 commit comments