Skip to content

Commit

Permalink
ci: Add a registry cache for git protocol
Browse files Browse the repository at this point in the history
  • Loading branch information
cuviper committed Feb 6, 2024
1 parent 33bd355 commit d0c41bd
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 0 deletions.
9 changes: 9 additions & 0 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,11 @@ jobs:
]
steps:
- uses: actions/checkout@v3
- uses: actions/cache@v4
if: startsWith(matrix.rust, '1')
with:
path: ~/.cargo/registry/index
key: cargo-${{ matrix.rust }}-git-index
- uses: dtolnay/rust-toolchain@master
with:
toolchain: ${{ matrix.rust }}
Expand All @@ -40,6 +45,10 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/cache@v4
with:
path: ~/.cargo/registry/index
key: cargo-1.31.0-git-index
- uses: dtolnay/[email protected]
with:
target: thumbv6m-none-eabi
Expand Down
5 changes: 5 additions & 0 deletions .github/workflows/master.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,11 @@ jobs:
rust: [1.31.0, stable]
steps:
- uses: actions/checkout@v3
- uses: actions/cache@v4
if: startsWith(matrix.rust, '1')
with:
path: ~/.cargo/registry/index
key: cargo-${{ matrix.rust }}-git-index
- uses: dtolnay/rust-toolchain@master
with:
toolchain: ${{ matrix.rust }}
Expand Down
5 changes: 5 additions & 0 deletions .github/workflows/pr.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,11 @@ jobs:
rust: [1.31.0, stable]
steps:
- uses: actions/checkout@v3
- uses: actions/cache@v4
if: startsWith(matrix.rust, '1')
with:
path: ~/.cargo/registry/index
key: cargo-${{ matrix.rust }}-git-index
- uses: dtolnay/rust-toolchain@master
with:
toolchain: ${{ matrix.rust }}
Expand Down

0 comments on commit d0c41bd

Please sign in to comment.