update ccache

fix ccache implementation
main
qurious-pixel 2021-01-19 10:45:23 -08:00 committed by GitHub
parent fc2ebf72a3
commit a975e1dac2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 9 additions and 4 deletions

View File

@ -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"