about summary refs log tree commit diff
diff options
context:
space:
mode:
authorantoyo <antoyo@users.noreply.github.com>2022-07-10 10:42:04 -0400
committerGitHub <noreply@github.com>2022-07-10 10:42:04 -0400
commit22e4f181cb9c5b376333b213ce92b8ebe55fb230 (patch)
treeaa51c86990f22b19ddd408ea4a16ad1ce8bdb68f
parent7c9db86fa1c6800bfbfbffd8036a29870ce1745a (diff)
parent28b11119e720f1af0e9f3dd854ee2e4618ff185d (diff)
downloadrust-22e4f181cb9c5b376333b213ce92b8ebe55fb230.tar.gz
rust-22e4f181cb9c5b376333b213ce92b8ebe55fb230.zip
Merge pull request #201 from GuillaumeGomez/cache-rust
Add cache for rust repository
-rw-r--r--.github/workflows/ci.yml9
1 files changed, 9 insertions, 0 deletions
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index 22f67a04e0b..8b36fa0c1c7 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -95,6 +95,15 @@ jobs:
         path: target
         key: ${{ runner.os }}-cargo-build-target-${{ hashFiles('rust-toolchain') }}
 
+    - name: Cache rust repository
+      # We only clone the rust repository for rustc tests
+      if: ${{ contains(matrix.commands, 'rustc') }}
+      uses: actions/cache@v2
+      id: cache-rust-repository
+      with:
+        path: rust
+        key: ${{ runner.os }}-packages-${{ hashFiles('rust/.git/HEAD') }}
+
     - name: Build
       run: |
         ./prepare_build.sh