Skip to content

Commit 92b0789

Browse files
authored
[ci] Skip sccache on Windows runners (vercel#92847)
## What Skip the sccache setup step when running on Windows. ## Why sccache is currently not "winning" with cache hits when building on Windows which is increasing the size of the turborepo cache. In addition, sccache servers appear to be lingering on some of the windows runners.
1 parent c5ddf82 commit 92b0789

1 file changed

Lines changed: 6 additions & 1 deletion

File tree

.github/workflows/build_reusable.yml

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -213,6 +213,11 @@ jobs:
213213
- run: corepack enable
214214
- run: pwd
215215

216+
- name: Kill stale sccache processes
217+
if: ${{ runner.os == 'Windows' }}
218+
shell: powershell
219+
run: Get-Process sccache -ErrorAction SilentlyContinue | Stop-Process -Force
220+
216221
- run: rm -rf .git
217222

218223
- uses: actions/checkout@v4
@@ -264,7 +269,7 @@ jobs:
264269

265270
- name: Start sccache
266271
uses: ./.github/actions/sccache
267-
if: ${{ (inputs.uploadNativeArtifact != '') || inputs.needsNextest == 'yes' || inputs.needsRust == 'yes' }}
272+
if: ${{ runner.os != 'Windows' && ((inputs.uploadNativeArtifact != '') || inputs.needsNextest == 'yes' || inputs.needsRust == 'yes') }}
268273
with:
269274
turbo-token: ${{ secrets.TURBO_REMOTE_CACHE_TOKEN }}
270275

0 commit comments

Comments
 (0)