Open shi-scala opened 1 year ago
That's by design: https://github.com/hendrikmuhs/ccache-action/pull/4
The cache doesn't work like a build, a cache is:
If an error occurs in step 2, the cache still contains the cache objects from step 1, the previous, potentially successful build.
Is there a way I can signal ccache-action not to cache results in case of failure?
I've noticed an issue, where if the compilation step fails for any reason, the cache is still created. Since created caches are not overwritten, partial builds are written and can not be overwritten.
I can use some combination of
append-timestamp
andrestore-keys
but this feels awkward and brittle.Is there a way to signal ccache-action to only save if an env variable is set or something similar?