diff options
author | Khải <hvksmr1996@gmail.com> | 2020-04-14 23:41:42 +0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-04-14 12:41:42 -0400 |
commit | e4c130d89b80c8c214df0f48af254023f5b5de15 (patch) | |
tree | 1ac456fc56a210709ffd9f04b15c37bee9688861 | |
parent | e08ece2d2cc2c39b067dc271f52516bdee7c06ca (diff) |
ci: Set restore-keys for cache (#4745)
Before this commit, when Cargo.lock changes, cache is completely rebuilt, wasting time.
After this commit, if cache for a specific Cargo.lock is not found, it will fallback to find cache of another Cargo.lock.
-rw-r--r-- | .github/workflows/ci.yml | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 8fcbacda6..d7381d9c4 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -110,6 +110,10 @@ jobs: target/*/gn_out key: ${{ matrix.config.os }}-${{ matrix.config.kind }}-${{ hashFiles('Cargo.lock') }} + restore-keys: | + ${{ matrix.config.os }}-${{ matrix.config.kind }}-${{ hashFiles('Cargo.lock') }} + ${{ matrix.config.os }}-${{ matrix.config.kind }}- + ${{ matrix.config.os }}- - name: lint.py if: matrix.config.kind == 'lint' |