mirror of
https://github.com/actions/cache.git
synced 2026-07-01 17:41:39 +00:00
Compare commits
6 Commits
05153f9c9b
...
2f41fdded1
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
2f41fdded1 | ||
|
|
27d5ce7f10 | ||
|
|
f280785d7b | ||
|
|
619aeb1606 | ||
|
|
bcf16c2893 | ||
|
|
0b16518fff |
BIN
.licenses/npm/@typespec/ts-http-runtime.dep.yml
generated
BIN
.licenses/npm/@typespec/ts-http-runtime.dep.yml
generated
Binary file not shown.
7867
dist/restore-only/index.js
vendored
7867
dist/restore-only/index.js
vendored
File diff suppressed because it is too large
Load Diff
7867
dist/restore/index.js
vendored
7867
dist/restore/index.js
vendored
File diff suppressed because it is too large
Load Diff
7867
dist/save-only/index.js
vendored
7867
dist/save-only/index.js
vendored
File diff suppressed because it is too large
Load Diff
7867
dist/save/index.js
vendored
7867
dist/save/index.js
vendored
File diff suppressed because it is too large
Load Diff
25
examples.md
25
examples.md
@ -25,6 +25,7 @@
|
|||||||
- [Node - Yarn](#node---yarn)
|
- [Node - Yarn](#node---yarn)
|
||||||
- [Node - Yarn 2](#node---yarn-2)
|
- [Node - Yarn 2](#node---yarn-2)
|
||||||
- [OCaml/Reason - esy](#ocamlreason---esy)
|
- [OCaml/Reason - esy](#ocamlreason---esy)
|
||||||
|
- [OCaml/Reason - opam](#ocamlreason---opam)
|
||||||
- [PHP - Composer](#php---composer)
|
- [PHP - Composer](#php---composer)
|
||||||
- [Python - pip](#python---pip)
|
- [Python - pip](#python---pip)
|
||||||
- [Simple example](#simple-example)
|
- [Simple example](#simple-example)
|
||||||
@ -437,6 +438,30 @@ Esy allows you to export built dependencies and import pre-built dependencies.
|
|||||||
if: steps.restore-cache.outputs.cache-hit != 'true'
|
if: steps.restore-cache.outputs.cache-hit != 'true'
|
||||||
```
|
```
|
||||||
|
|
||||||
|
## OCaml/Reason - opam
|
||||||
|
|
||||||
|
This example requires you to have `opam.locked` file which you can generate with `opam lock .`.
|
||||||
|
|
||||||
|
It's worth noting that even if lock file was change, it might be optimal to restore previous cache, so `hashFiles` in the key and if statement in "Save opam cache" step are optional.
|
||||||
|
```yaml
|
||||||
|
- name: Restore opam cache
|
||||||
|
id: restore-cache
|
||||||
|
uses: actions/cache/restore@v4
|
||||||
|
with:
|
||||||
|
path: _opam
|
||||||
|
key: ${{ runner.os }}-opam-${{ hashFiles('opam.locked') }}
|
||||||
|
|
||||||
|
- name: Install dependencies
|
||||||
|
run: opam install . --locked --deps-only -y
|
||||||
|
|
||||||
|
- name: Save opam cache
|
||||||
|
if: steps.restore-cache.outputs.cache-hit != 'true'
|
||||||
|
uses: actions/cache/save@v4
|
||||||
|
with:
|
||||||
|
path: _opam
|
||||||
|
key: ${{ steps.restore-cache.outputs.cache-primary-key }}
|
||||||
|
```
|
||||||
|
|
||||||
## PHP - Composer
|
## PHP - Composer
|
||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
|
|||||||
6
package-lock.json
generated
6
package-lock.json
generated
@ -1945,9 +1945,9 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@typespec/ts-http-runtime": {
|
"node_modules/@typespec/ts-http-runtime": {
|
||||||
"version": "0.3.2",
|
"version": "0.3.5",
|
||||||
"resolved": "https://registry.npmjs.org/@typespec/ts-http-runtime/-/ts-http-runtime-0.3.2.tgz",
|
"resolved": "https://registry.npmjs.org/@typespec/ts-http-runtime/-/ts-http-runtime-0.3.5.tgz",
|
||||||
"integrity": "sha512-IlqQ/Gv22xUC1r/WQm4StLkYQmaaTsXAhUVsNE0+xiyf0yRFiH5++q78U3bw6bLKDCTmh0uqKB9eG9+Bt75Dkg==",
|
"integrity": "sha512-yURCknZhvywvQItHMMmFSo+fq5arCUIyz/CVk7jD89MSai7dkaX8ufjCWp3NttLojoTVbcE72ri+be/TnEbMHw==",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"http-proxy-agent": "^7.0.0",
|
"http-proxy-agent": "^7.0.0",
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user