From d1ae0bd5767bb1a927483f88a126d7a2d805eab0 Mon Sep 17 00:00:00 2001 From: Evan Pete Walsh Date: Fri, 17 Jan 2020 13:30:08 -0800 Subject: [PATCH] Cache cargo registry and build target directory in CI (#78) * try caching cargo registry and build * trigger build * try fixing path * force build * try different cache key * try rebuild --- .github/workflows/rust.yml | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/.github/workflows/rust.yml b/.github/workflows/rust.yml index 60174242..200a3fef 100644 --- a/.github/workflows/rust.yml +++ b/.github/workflows/rust.yml @@ -19,6 +19,18 @@ jobs: components: rustfmt, clippy override: true + - name: Cache Cargo Registry + uses: actions/cache@v1 + with: + path: ~/.cargo/registry + key: ${{ runner.os }}-cargo-registry-${{ hashFiles('**/Cargo.toml') }} + + - name: Cache Cargo Build Target + uses: actions/cache@v1 + with: + path: tokenizers/target + key: ${{ runner.os }}-cargo-build-${{ hashFiles('**/Cargo.toml') }} + - name: Build uses: actions-rs/cargo@v1 with: