From b4d69879370e56dbaa7e6e0ea2a4d667bcd5b004 Mon Sep 17 00:00:00 2001 From: Eliot Partridge Date: Mon, 21 Oct 2024 11:52:42 -0400 Subject: [PATCH] Rename to `isExactCacheKeyMatch` --- bundler.js | 2 +- common.js | 2 +- dist/index.js | 6 +++--- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/bundler.js b/bundler.js index ffe179cb5..6d3c22686 100644 --- a/bundler.js +++ b/bundler.js @@ -209,7 +209,7 @@ export async function bundleInstall(gemfile, lockFile, platform, engine, rubyVer await exec.exec('bundle', ['install', '--jobs', '4']) // @actions/cache only allows to save for non-existing keys - if (!common.isExactKeyMatch(key, cachedKey)) { + if (!common.isExactCacheKeyMatch(key, cachedKey)) { if (cachedKey) { // existing cache but Gemfile.lock differs, clean old gems await exec.exec('bundle', ['clean']) } diff --git a/common.js b/common.js index eb9f40f78..b2d337ada 100644 --- a/common.js +++ b/common.js @@ -397,7 +397,7 @@ export function setupPath(newPathEntries) { // Determines if two keys are an exact match for the purposes of cache matching // Specifically, this is a case-insensitive match that ignores accents // From actions/cache@v3 src/utils/actionUtils.ts (MIT) -export function isExactKeyMatch(key, cacheKey) { +export function isExactCacheKeyMatch(key, cacheKey) { return !!( cacheKey && cacheKey.localeCompare(key, undefined, { diff --git a/dist/index.js b/dist/index.js index 80bee745f..bbd0febdb 100644 --- a/dist/index.js +++ b/dist/index.js @@ -223,7 +223,7 @@ async function bundleInstall(gemfile, lockFile, platform, engine, rubyVersion, b await exec.exec('bundle', ['install', '--jobs', '4']) // @actions/cache only allows to save for non-existing keys - if (!common.isExactKeyMatch(key, cachedKey)) { + if (!common.isExactCacheKeyMatch(key, cachedKey)) { if (cachedKey) { // existing cache but Gemfile.lock differs, clean old gems await exec.exec('bundle', ['clean']) } @@ -316,7 +316,7 @@ __nccwpck_require__.r(__webpack_exports__); /* harmony export */ "createToolCacheCompleteFile": () => (/* binding */ createToolCacheCompleteFile), /* harmony export */ "win2nix": () => (/* binding */ win2nix), /* harmony export */ "setupPath": () => (/* binding */ setupPath), -/* harmony export */ "isExactKeyMatch": () => (/* binding */ isExactKeyMatch) +/* harmony export */ "isExactCacheKeyMatch": () => (/* binding */ isExactCacheKeyMatch) /* harmony export */ }); const os = __nccwpck_require__(2037) const path = __nccwpck_require__(1017) @@ -717,7 +717,7 @@ function setupPath(newPathEntries) { // Determines if two keys are an exact match for the purposes of cache matching // Specifically, this is a case-insensitive match that ignores accents // From actions/cache@v3 src/utils/actionUtils.ts (MIT) -function isExactKeyMatch(key, cacheKey) { +function isExactCacheKeyMatch(key, cacheKey) { return !!( cacheKey && cacheKey.localeCompare(key, undefined, {