From a975e1dac2ac06aa60ac503d7f9798987c2c2a2f Mon Sep 17 00:00:00 2001 From: qurious-pixel <62252937+qurious-pixel@users.noreply.github.com> Date: Tue, 19 Jan 2021 10:45:23 -0800 Subject: [PATCH] update ccache fix ccache implementation --- .github/workflows/build.yml | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index a0d296a96..8851b81e8 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -12,14 +12,19 @@ jobs: steps: - name: Checkout code uses: actions/checkout@v2 - + - name: Prepare ccache timestamp + id: ccache_cache_timestamp + shell: cmake -P {0} + run: | + string(TIMESTAMP current_date "%Y-%m-%d-%H;%M;%S" UTC) + message("::set-output name=timestamp::${current_date}") - name: cache uses: actions/cache@v2 with: - path: $HOME/.ccache - key: build-ccache + path: ~/.ccache + key: build-ccache-${{ steps.ccache_cache_timestamp.outputs.timestamp }} restore-keys: | - build-ccache + build-ccache- - name: Build binary run: | mkdir -p "$HOME/.ccache"