From b28dbaf08e5be9409ce2dfa3373968b2ea1ac700 Mon Sep 17 00:00:00 2001 From: Eliza Brock Marcum Date: Wed, 24 Jun 2020 14:55:55 -0500 Subject: [PATCH] For testing in my build --- dist/restore/index.js | 1 + dist/save/index.js | 10 ++++++++-- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/dist/restore/index.js b/dist/restore/index.js index 00349f4..811694c 100644 --- a/dist/restore/index.js +++ b/dist/restore/index.js @@ -6717,6 +6717,7 @@ var Inputs; Inputs["Key"] = "key"; Inputs["Path"] = "path"; Inputs["RestoreKeys"] = "restore-keys"; + Inputs["Update"] = "update"; })(Inputs = exports.Inputs || (exports.Inputs = {})); var Outputs; (function (Outputs) { diff --git a/dist/save/index.js b/dist/save/index.js index f733e9a..b9ba86f 100644 --- a/dist/save/index.js +++ b/dist/save/index.js @@ -6605,8 +6605,13 @@ function run() { return; } if (utils.isExactKeyMatch(primaryKey, state)) { - core.info(`Cache hit occurred on the primary key ${primaryKey}, not saving cache.`); - return; + if (core.getInput(constants_1.Inputs.Update) === "true") { + core.info(`Cache hit occurred on the primary key ${primaryKey}, but updates were enabled, so updating cache.`); + } + else { + core.info(`Cache hit occurred on the primary key ${primaryKey}, not saving cache.`); + return; + } } const cachePaths = utils.getInputAsArray(constants_1.Inputs.Path, { required: true @@ -6802,6 +6807,7 @@ var Inputs; Inputs["Key"] = "key"; Inputs["Path"] = "path"; Inputs["RestoreKeys"] = "restore-keys"; + Inputs["Update"] = "update"; })(Inputs = exports.Inputs || (exports.Inputs = {})); var Outputs; (function (Outputs) {