Skip to content

Commit f1d1c2c

Browse files
committed
build/windows: consolidate cache into single operation
Signed-off-by: deadprogram <[email protected]>
1 parent 3c16558 commit f1d1c2c

File tree

1 file changed

+12
-25
lines changed

1 file changed

+12
-25
lines changed

.github/workflows/windows.yml

Lines changed: 12 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -37,37 +37,18 @@ jobs:
3737
with:
3838
go-version: '1.20'
3939
cache: true
40-
- name: Restore cached LLVM source
40+
- name: Restore cached LLVM build
4141
uses: actions/cache/restore@v3
42-
id: cache-llvm-source
43-
with:
44-
key: llvm-source-15-windows-v2-${{ hashFiles('llvm-project/llvm/include') }}
45-
path: |
46-
llvm-project/clang/lib/Headers
47-
llvm-project/clang/include
48-
llvm-project/compiler-rt
49-
llvm-project/lld/include
50-
llvm-project/llvm/include
51-
- name: Download LLVM source
52-
if: steps.cache-llvm-source.outputs.cache-hit != 'true'
53-
run: make llvm-source
54-
- name: Save cached LLVM source
55-
uses: actions/cache/save@v3
56-
if: always()
42+
id: cache-llvm-build
5743
with:
58-
key: llvm-source-15-windows-v2-${{ hashFiles('llvm-project/llvm/include') }}
44+
key: llvm-build-15-windows-v3-${{ hashFiles('llvm-project/llvm/include') }}
5945
path: |
6046
llvm-project/clang/lib/Headers
6147
llvm-project/clang/include
6248
llvm-project/compiler-rt
6349
llvm-project/lld/include
6450
llvm-project/llvm/include
65-
- name: Restore cached LLVM build
66-
uses: actions/cache/restore@v3
67-
id: cache-llvm-build
68-
with:
69-
key: llvm-build-15-windows-v3-${{ hashFiles('llvm-build') }}
70-
path: llvm-build
51+
llvm-build
7152
- name: Build LLVM
7253
if: steps.cache-llvm-build.outputs.cache-hit != 'true'
7354
shell: bash
@@ -83,8 +64,14 @@ jobs:
8364
uses: actions/cache/save@v3
8465
if: always()
8566
with:
86-
key: llvm-build-15-windows-v3-${{ hashFiles('llvm-build') }}
87-
path: llvm-build
67+
key: llvm-build-15-windows-v3-${{ hashFiles('llvm-project/llvm/include') }}
68+
path: |
69+
llvm-project/clang/lib/Headers
70+
llvm-project/clang/include
71+
llvm-project/compiler-rt
72+
llvm-project/lld/include
73+
llvm-project/llvm/include
74+
llvm-build
8875
- name: Cache wasi-libc sysroot
8976
uses: actions/cache@v3
9077
id: cache-wasi-libc

0 commit comments

Comments
 (0)