Skip to content

Commit 6688556

Browse files
committed
Cache Support: Try 3
1 parent b72c8eb commit 6688556

File tree

1 file changed

+8
-4
lines changed

1 file changed

+8
-4
lines changed

.github/workflows/build.yml

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -43,17 +43,21 @@ jobs:
4343

4444
# Cache APT packages
4545
- name: Cache APT Packages
46-
uses: actions/cache@v4
46+
id: cache-apt
47+
uses: awalsh128/cache-apt-pkgs-action@latest
4748
with:
48-
path: /var/cache/apt/archives
49-
key: apt-packages-${{ runner.os }}-v1
50-
save-always: true
49+
packages: repo python3 python-is-python3 ccache
50+
version: 1.0
5151

5252
- name: Install Repo and Python
53+
if: steps.cache-apt.outputs.cache-hit != 'true'
5354
run: |
5455
# Install dependencies
5556
sudo apt update
5657
sudo apt install repo python3 python-is-python3 ccache
58+
59+
- name: Setup ccache
60+
run: |
5761
echo "CCACHE_DIR=$(pwd)/ccache" >> $GITHUB_ENV
5862
echo "PATH=/usr/lib/ccache:$PATH" >> $GITHUB_ENV
5963

0 commit comments

Comments
 (0)