Skip to content

Commit df4cdc5

Browse files
authored
Merge pull request #165 from anirul/codex/frame-ci-sccache
Enable sccache in Linux CI
2 parents 5d41837 + 0742fbf commit df4cdc5

1 file changed

Lines changed: 15 additions & 1 deletion

File tree

.github/workflows/main.yml

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,10 @@ on:
66
jobs:
77
build:
88
runs-on: ubuntu-latest
9+
env:
10+
SCCACHE_GHA_ENABLED: "true"
11+
SCCACHE_CACHE_SIZE: "2G"
12+
SCCACHE_IGNORE_SERVER_IO_ERROR: "1"
913

1014
steps:
1115
- name: Checkout code
@@ -14,6 +18,9 @@ jobs:
1418
lfs: true
1519
submodules: true
1620

21+
- name: Setup sccache
22+
uses: mozilla-actions/sccache-action@v0.0.9
23+
1724
- name: Git-lfs pull
1825
run: |
1926
git lfs pull
@@ -68,7 +75,10 @@ jobs:
6875
# No need for a manual vcpkg install step, the manifest mode will handle it
6976

7077
- name: Configure with CMake Preset
71-
run: cmake --preset linux-release
78+
run: >
79+
cmake --preset linux-release
80+
-DCMAKE_C_COMPILER_LAUNCHER=sccache
81+
-DCMAKE_CXX_COMPILER_LAUNCHER=sccache
7282
7383
- name: Build with CMake Preset
7484
run: cmake --build --preset linux-release
@@ -77,3 +87,7 @@ jobs:
7787
run: |
7888
cd build/linux-release
7989
xvfb-run ctest --output-on-failure
90+
91+
- name: Show sccache stats
92+
if: always()
93+
run: ${SCCACHE_PATH} --show-stats

0 commit comments

Comments
 (0)