mirror of
https://github.com/actions/cache.git
synced 2026-01-13 17:13:06 +08:00
Compare commits
3 Commits
c0690d431b
...
c78c232659
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
c78c232659 | ||
|
|
53aa38c736 | ||
|
|
9efb3f33bc |
@ -209,6 +209,9 @@ A cache key can include any of the contexts, functions, literals, and operators
|
||||
|
||||
For example, using the [`hashFiles`](https://docs.github.com/en/actions/learn-github-actions/expressions#hashfiles) function allows you to create a new cache when dependencies change.
|
||||
|
||||
> [!NOTE]
|
||||
> The cache key is rendered during the restore stage, so can only depend on file state at that stage.
|
||||
|
||||
```yaml
|
||||
- uses: actions/cache@v4
|
||||
with:
|
||||
|
||||
@ -102,7 +102,7 @@ The [GitHub Context](https://docs.github.com/en/actions/learn-github-actions/con
|
||||
|
||||
While setting paths for caching dependencies it is important to give correct path depending on the hosted runner you are using or whether the action is running in a container job. Assigning different `path` for save and restore will result in cache miss.
|
||||
|
||||
Below are GiHub hosted runner specific paths one should take care of when writing a workflow which saves/restores caches across OS.
|
||||
Below are GitHub hosted runner specific paths one should take care of when writing a workflow which saves/restores caches across OS.
|
||||
|
||||
#### Ubuntu Paths
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user