From c9276fc739365f9317d411bcf32ca8dea3d39142 Mon Sep 17 00:00:00 2001 From: Jonathan Kelley Date: Tue, 28 Jan 2025 18:38:08 -0800 Subject: [PATCH] make sure to invalidate cache --- src/config.ts | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/config.ts b/src/config.ts index c71db36..f1102d6 100644 --- a/src/config.ts +++ b/src/config.ts @@ -62,7 +62,7 @@ export class CacheConfig { let key = core.getInput("prefix-key") || "v0-rust"; - self.incremental = core.getInput("incremental").toLowerCase() == "true"; + const sharedKey = core.getInput("shared-key"); if (sharedKey) { @@ -124,6 +124,10 @@ export class CacheConfig { self.restoreKey = key; + // Make sure we consider incremental builds + self.incremental = core.getInput("incremental").toLowerCase() == "true"; + hasher.update(`incremental=${self.incremental}`); + // Construct the lockfiles portion of the key: // This considers all the files found via globbing for various manifests // and lockfiles.