mirror of
https://github.com/Swatinem/rust-cache
synced 2026-07-17 03:45:43 +00:00
Bumps the actions group with 2 updates: [actions/checkout](https://github.com/actions/checkout) and [taiki-e/install-action](https://github.com/taiki-e/install-action).
Updates `actions/checkout` from 6.0.3 to 7.0.0
- [Release notes](https://github.com/actions/checkout/releases)
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/checkout/compare/v6.0.3...9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0)
Updates `taiki-e/install-action` from 2.82.2 to 2.82.9
- [Release notes](https://github.com/taiki-e/install-action/releases)
- [Changelog](https://github.com/taiki-e/install-action/blob/main/CHANGELOG.md)
- [Commits](9e1e5806d4...4684b84056)
---
updated-dependencies:
- dependency-name: actions/checkout
dependency-version: 7.0.0
dependency-type: direct:production
update-type: version-update:semver-major
dependency-group: actions
- dependency-name: taiki-e/install-action
dependency-version: 2.82.9
dependency-type: direct:production
update-type: version-update:semver-patch
dependency-group: actions
...
Signed-off-by: dependabot[bot] <support@github.com>
70 lines
1.8 KiB
YAML
70 lines
1.8 KiB
YAML
name: save-restore
|
|
|
|
on: [push, pull_request]
|
|
|
|
permissions: {}
|
|
|
|
jobs:
|
|
save:
|
|
if: github.repository == 'Swatinem/rust-cache'
|
|
strategy:
|
|
fail-fast: false
|
|
matrix:
|
|
os: [ubuntu-latest, macos-latest, windows-latest]
|
|
|
|
name: Save a new cache on ${{ matrix.os }}
|
|
runs-on: ${{ matrix.os }}
|
|
|
|
env:
|
|
CARGO_TERM_COLOR: always
|
|
|
|
steps:
|
|
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
|
|
with:
|
|
persist-credentials: false
|
|
|
|
- run: rustup toolchain install stable --profile minimal --no-self-update
|
|
|
|
# Use a per-run key so this job always exercises the post-step save path.
|
|
- uses: ./
|
|
with:
|
|
workspaces: tests
|
|
shared-key: save-restore-${{ matrix.os }}-${{ github.run_id }}-${{ github.run_attempt }}
|
|
|
|
- run: cargo check
|
|
working-directory: tests
|
|
|
|
restore:
|
|
if: github.repository == 'Swatinem/rust-cache'
|
|
strategy:
|
|
fail-fast: false
|
|
matrix:
|
|
os: [ubuntu-latest, macos-latest, windows-latest]
|
|
|
|
name: Restore the newly saved cache on ${{ matrix.os }}
|
|
needs: save
|
|
runs-on: ${{ matrix.os }}
|
|
|
|
env:
|
|
CARGO_TERM_COLOR: always
|
|
|
|
steps:
|
|
- uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
|
|
with:
|
|
persist-credentials: false
|
|
|
|
- run: rustup toolchain install stable --profile minimal --no-self-update
|
|
|
|
- id: cache
|
|
uses: ./
|
|
with:
|
|
workspaces: tests
|
|
shared-key: save-restore-${{ matrix.os }}-${{ github.run_id }}-${{ github.run_attempt }}
|
|
save-if: "false"
|
|
|
|
- name: Verify exact cache hit
|
|
if: steps.cache.outputs.cache-hit != 'true'
|
|
shell: bash
|
|
run: |
|
|
echo "The cache created by the save job could not be restored." >&2
|
|
exit 1
|