From 9d6a0399f5be344cc28931691a3d23d617324ebc Mon Sep 17 00:00:00 2001 From: Luke Street Date: Fri, 15 Aug 2025 16:58:32 -0600 Subject: [PATCH] Add cache restore-keys to always update cache NOTE: See https://github.com/encounter/dtk-template-build/commit/9408cb2cdc65750f9099d58783adc2936c0831ba zstd is added as a package to significantly improve cache update time. --- .github.example/workflows/build.yml | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/.github.example/workflows/build.yml b/.github.example/workflows/build.yml index e3e990a..66c8137 100644 --- a/.github.example/workflows/build.yml +++ b/.github.example/workflows/build.yml @@ -31,7 +31,9 @@ jobs: # Normalize file mod times - name: Restore timestamps - run: uv run https://raw.githubusercontent.com/MestreLion/git-tools/refs/tags/v2022.12/git-restore-mtime --merge --commit-time + run: | + uv run https://raw.githubusercontent.com/MestreLion/git-tools/refs/tags/v2022.12/git-restore-mtime \ + --merge --commit-time # Copy the original files to the workspace - name: Prepare @@ -45,7 +47,8 @@ jobs: build .ninja_deps .ninja_log - key: ${{ runner.os }}-${{ matrix.version }} + key: ${{ runner.os }}-${{ matrix.version }}-${{ github.sha }} + restore-keys: ${{ runner.os }}-${{ matrix.version }}- # Build the project - name: Build