Skip to content

Commit d0f20ed

Browse files
committed
use actions/cache for scripts/install.sh
Signed-off-by: Aaron Wislang <aaron.wislang@microsoft.com>
1 parent 12764a8 commit d0f20ed

1 file changed

Lines changed: 18 additions & 0 deletions

File tree

.github/workflows/publish.yml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,24 @@ jobs:
1717
- name: Checkout repository
1818
uses: actions/checkout@v2
1919

20+
- name: Cache cargo bin
21+
id: cache-cargo
22+
uses: actions/cache@v3
23+
env:
24+
cache-name: cache-cargo-bin
25+
with:
26+
path: ~/.cargo/bin
27+
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('scripts/install.sh') }}
28+
restore-keys: |
29+
${{ runner.os }}-build-${{ env.cache-name }}-
30+
${{ runner.os }}-build-
31+
${{ runner.os }}-
32+
33+
- if: ${{ steps.cache-cargo.outputs.cache-hit != 'true' }}
34+
name: Run install script
35+
continue-on-error: false
36+
run: bash scripts/install.sh
37+
2038
- name: Run build script
2139
run: bash scripts/build.sh
2240

0 commit comments

Comments
 (0)