aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHampusM <hampus@hampusmat.com>2022-11-11 20:34:06 +0100
committerHampusM <hampus@hampusmat.com>2022-11-11 20:34:06 +0100
commitd9d649f8578c616b0672d807ddbbeb09ba2d88ea (patch)
treefc730b143e6c43e9fb15c3207d8db385df908046
parent4d9ef47fd15c2f7c83569c647f3b5afcbb79bded (diff)
ci: add caching of Cargo data
-rw-r--r--.circleci/config.yml27
1 files changed, 27 insertions, 0 deletions
diff --git a/.circleci/config.yml b/.circleci/config.yml
index 4355f4b..eb18dd7 100644
--- a/.circleci/config.yml
+++ b/.circleci/config.yml
@@ -13,12 +13,21 @@ jobs:
- run:
name: Setting Rust nightly as default
command: rustup default nightly
+ - restore_cache:
+ name: Restore cache of Cargo data
+ keys:
+ - cargo-cache
- run:
name: Run tests with all features enabled
command: cargo test --workspace --all-features
- run:
name: Run tests with only default features enabled
command: cargo test --workspace
+ - save_cache:
+ name: Save cache of Cargo data
+ key: cargo-cache
+ paths:
+ - ~/.cargo
test-stable:
docker:
@@ -26,12 +35,21 @@ jobs:
steps:
- checkout
- run: cargo --version
+ - restore_cache:
+ name: Restore cache of Cargo data
+ keys:
+ - cargo-cache
- run:
name: Run tests with all features except factory enabled
command: cargo test --workspace --features async
- run:
name: Run tests with only default features enabled
command: cargo test --workspace
+ - save_cache:
+ name: Save cache of Cargo data
+ key: cargo-cache
+ paths:
+ - ~/.cargo
coverage:
machine: true
@@ -59,9 +77,18 @@ jobs:
steps:
- checkout
- run: cargo --version
+ - restore_cache:
+ name: Restore cache of Cargo data
+ keys:
+ - cargo-cache
- run:
name: Run Clippy
command: cargo clippy
+ - save_cache:
+ name: Save cache of Cargo data
+ key: cargo-cache
+ paths:
+ - ~/.cargo
code-style:
docker: