mirror of
https://github.com/actions/cache.git
synced 2026-03-01 08:11:03 +08:00
Compare commits
4 Commits
16f4207179
...
2acbcef99d
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
2acbcef99d | ||
|
|
5656298164 | ||
|
|
4e380d19e1 | ||
|
|
d722552897 |
@ -165,6 +165,10 @@ steps:
|
||||
run: /publish.sh
|
||||
```
|
||||
|
||||
> [!IMPORTANT]
|
||||
>
|
||||
> The `path` must match on both the centralized job and the target job, otherwise there will be no cache-hit whatsoever. Also take notes of the [restrictions for accessing caches across workflows](https://docs.github.com/en/actions/writing-workflows/choosing-what-your-workflow-does/caching-dependencies-to-speed-up-workflows#restrictions-for-accessing-a-cache).
|
||||
|
||||
### Failing/Exiting the workflow if cache with exact key is not found
|
||||
|
||||
You can use the output of this action to exit the workflow on cache miss. This way you can restrict your workflow to only initiate the build when `cache-hit` occurs, in other words, cache with exact key is found.
|
||||
|
||||
@ -49,7 +49,7 @@
|
||||
with:
|
||||
path: |
|
||||
~/.bun/install/cache
|
||||
key: ${{ runner.os }}-bun-${{ hashFiles('**/bun.lockb') }}
|
||||
key: ${{ runner.os }}-bun-${{ hashFiles('**/bun.lock') }}
|
||||
```
|
||||
|
||||
### Windows
|
||||
@ -59,7 +59,7 @@
|
||||
with:
|
||||
path: |
|
||||
~\.bun
|
||||
key: ${{ runner.os }}-bun-${{ hashFiles('**/bun.lockb') }}
|
||||
key: ${{ runner.os }}-bun-${{ hashFiles('**/bun.lock') }}
|
||||
```
|
||||
|
||||
## C# - NuGet
|
||||
|
||||
Loading…
Reference in New Issue
Block a user