File tree Expand file tree Collapse file tree 1 file changed +13
-3
lines changed
Expand file tree Collapse file tree 1 file changed +13
-3
lines changed Original file line number Diff line number Diff line change @@ -39,11 +39,14 @@ jobs:
3939 - name : Checkout code
4040 uses : actions/checkout@v2
4141
42- - name : Setup package cache
43- uses : actions/cache@v4
42+ - name : Load package cache
43+ uses : actions/cache/restore @v4
4444 with :
4545 path : pkg-cache
46- key : ${{ matrix.os }}-pkg-cache
46+ key : ${{ matrix.os }}-pkg-cache-${{ github.head_ref || "main" }}-${{ github.sha }}
47+ restore-keys : |
48+ ${{ matrix.os }}-pkg-cache-${{ github.head_ref || "main" }}-
49+ ${{ matrix.os }}-pkg-cache-main-
4750
4851 - name : Initialise Docker image
4952 run : |
@@ -124,3 +127,10 @@ jobs:
124127 -v "${{ github.workspace }}:/workspace":ro \
125128 "${{ matrix.os }}" \
126129 /bin/sh -c "${CMD}"
130+
131+ - name : Save package cache
132+ if : always()
133+ uses : actions/cache/save@v4
134+ with :
135+ path : pkg-cache
136+ key : ${{ matrix.os }}-pkg-cache-${{ github.head_ref || "main" }}-${{ github.sha }}
You can’t perform that action at this time.
0 commit comments