Add CachingKind enum to control whether to restore or store caches

This commit is contained in:
Michael B. Gale
2024-10-14 09:51:23 +01:00
parent 668531eca8
commit 79faaf1396
15 changed files with 195 additions and 57 deletions

5
lib/config-utils.js generated
View File

@@ -53,6 +53,7 @@ const perf_hooks_1 = require("perf_hooks");
const yaml = __importStar(require("js-yaml"));
const semver = __importStar(require("semver"));
const api = __importStar(require("./api-client"));
const caching_utils_1 = require("./caching-utils");
const feature_flags_1 = require("./feature-flags");
const languages_1 = require("./languages");
const trap_caching_1 = require("./trap-caching");
@@ -232,7 +233,7 @@ async function getDefaultConfig({ languagesInput, queriesInput, packsInput, buil
augmentationProperties,
trapCaches,
trapCacheDownloadTime,
dependencyCachingEnabled,
dependencyCachingEnabled: (0, caching_utils_1.getCachingKind)(dependencyCachingEnabled),
};
}
async function downloadCacheWithTime(trapCachingEnabled, codeQL, languages, logger) {
@@ -282,7 +283,7 @@ async function loadConfig({ languagesInput, queriesInput, packsInput, buildModeI
augmentationProperties,
trapCaches,
trapCacheDownloadTime,
dependencyCachingEnabled,
dependencyCachingEnabled: (0, caching_utils_1.getCachingKind)(dependencyCachingEnabled),
};
}
/**