Change the cache key pattern

This commit is contained in:
Ivan Zosimov 2022-05-04 12:07:39 +02:00
parent 2d848c0e6a
commit b91ca81f0e
2 changed files with 2 additions and 2 deletions

2
dist/setup/index.js vendored
View file

@ -37266,7 +37266,7 @@ exports.restoreCache = (packageManager, cacheDependencyPath) => __awaiter(void 0
if (!fileHash) { if (!fileHash) {
throw new Error('Some specified paths were not resolved, unable to cache dependencies.'); throw new Error('Some specified paths were not resolved, unable to cache dependencies.');
} }
const primaryKey = `${platform}-go${versionSpec}-${fileHash}`; const primaryKey = `setup-go-${platform}-go-${versionSpec}-${fileHash}`;
core.debug(`primary key is ${primaryKey}`); core.debug(`primary key is ${primaryKey}`);
core.saveState(constants_1.State.CachePrimaryKey, primaryKey); core.saveState(constants_1.State.CachePrimaryKey, primaryKey);
const cacheKey = yield cache.restoreCache(cachePaths, primaryKey); const cacheKey = yield cache.restoreCache(cachePaths, primaryKey);

View file

@ -29,7 +29,7 @@ export const restoreCache = async (
); );
} }
const primaryKey = `${platform}-go${versionSpec}-${fileHash}`; const primaryKey = `setup-go-${platform}-go-${versionSpec}-${fileHash}`;
core.debug(`primary key is ${primaryKey}`); core.debug(`primary key is ${primaryKey}`);
core.saveState(State.CachePrimaryKey, primaryKey); core.saveState(State.CachePrimaryKey, primaryKey);