Skip to content

Conversation

@kbriggs
Copy link
Contributor

@kbriggs kbriggs commented Jan 12, 2026

Some self-hosted (or otherwise non-github-hosted) runners are non-case-preserving for cache keys. To support such configurations, set the cache-hit output variable to true if the found cache key matches case-insenitively.

Fixes: #302

Some self-hosted (or otherwise non-github-hosted) runners are
non-case-preserving for cache keys. To support such configurations, set the
`cache-hit` output variable to `true` if the found cache key matches
case-insenitively.

Fixes: Swatinem#302
@kbriggs
Copy link
Contributor Author

kbriggs commented Jan 12, 2026

Testing

With the change, with a codeberg action using my branch:

Cache Configuration
Cache Provider:
    github
…
Restore Key:
    v0-rust-cargodeps-Linux-x64-345d6b90
Cache Key:
    v0-rust-cargodeps-Linux-x64-345d6b90-10ea9ea9
.. Prefix:
  - v0-rust-cargodeps-Linux-x64
…
... Restoring cache ...
Cache Size: ~155 MB (162100487 B)
[command]/usr/bin/tar -xf /tmp/2b6d26c1-89f4-4f44-875f-cfcda9061c05/cache.tzst -P -C /workspace/kbriggs/airtouch5 --use-compress-program unzstd
Cache restored successfully
Restored from cache key "v0-rust-cargodeps-linux-x64-345d6b90-10ea9ea9" full match: true.

(and the subsequent cargo fetch step is correctly skipped, since cache-hit is now true)

@Swatinem Swatinem merged commit 11da852 into Swatinem:master Jan 12, 2026
32 of 33 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

cache-hit is false on case-insensitive cache key match

2 participants