Skip to content

Commit abc6e18

Browse files
committed
[CI] Fixed Windows sccache cache failing to save.
1 parent a0d1b84 commit abc6e18

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

.github/workflows/ClangSharp.Pathogen.yml

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,9 @@ jobs:
102102
uses: actions/cache@v2
103103
# If you change this configuration make sure to update keep-cache-warm.yml as well.
104104
with:
105+
# Note that this implicitly includes the sccache log
106+
# sccache writes a startup message to the log so you'll be able to tell which section of the log is the current run
107+
# (and see any logs from previous runs which affected this cache)
105108
path: ${{steps.sccache.outputs.root-directory}}
106109
key: sccache-cache-${{matrix.rid}}-${{steps.llvm.outputs.revision}}
107110
restore-keys: sccache-cache-${{matrix.rid}}-
@@ -125,7 +128,11 @@ jobs:
125128

126129
- name: Show sccache statistics
127130
if: steps.cached-llvm.outputs.cache-hit != 'true' && always()
128-
run: sccache --show-stats 2>&1 | tee ${{steps.sccache.outputs.root-directory}}/sccache-stats.txt
131+
run: |
132+
sccache --show-stats 2>&1 | tee ${{steps.sccache.outputs.root-directory}}/sccache-stats.txt
133+
# Stop the server so it releases the lock on the log on Windows
134+
# (Without this the sccache cache fails to save.)
135+
sccache --stop-server
129136
130137
- name: Save sccache logs
131138
uses: actions/upload-artifact@v2

0 commit comments

Comments
 (0)