File tree 1 file changed +28
-14
lines changed
1 file changed +28
-14
lines changed Original file line number Diff line number Diff line change
1
+ restore_registry : &RESTORE_REGISTRY
2
+ restore_cache :
3
+ key : registry
4
+ save_registry : &SAVE_REGISTRY
5
+ save_cache :
6
+ key : registry-{{ .BuildNum }}
7
+ paths :
8
+ - /usr/local/cargo/registry/index
9
+ deps_key : &DEPS_KEY
10
+ key : deps-{{ checksum "~/rust-version" }}-{{ checksum "Cargo.lock" }}
11
+ restore_deps : &RESTORE_DEPS
12
+ restore_cache :
13
+ << : *DEPS_KEY
14
+ save_deps : &SAVE_DEPS
15
+ save_cache :
16
+ << : *DEPS_KEY
17
+ paths :
18
+ - target
19
+ - /usr/local/cargo/registry/cache
20
+
1
21
version : 2
2
22
jobs :
3
23
build :
4
24
working_directory : ~/build
5
25
docker :
6
- - image : jimmycuadra/rust:1.19.0
26
+ - image : rust:1.20.0
27
+ environment :
28
+ RUSTFLAGS : -D warnings
7
29
- image : postgres:9.6
8
30
environment :
9
31
POSTGRES_PASSWORD : password
10
32
steps :
11
33
- checkout
12
- - restore_cache :
13
- key : registry
34
+ - *RESTORE_REGISTRY
14
35
- run : cargo generate-lockfile
15
- - save_cache :
16
- key : registry-{{ epoch }}
17
- paths :
18
- - ~/.cargo/registry/index
19
- - restore_cache :
20
- key : dependencies-1.19-{{ checksum "Cargo.lock" }}
36
+ - *SAVE_REGISTRY
37
+ - run : rustc --version > ~/rust-version
38
+ - *RESTORE_DEPS
21
39
- run : cargo test
22
- - save_cache :
23
- key : dependencies-1.19-{{ checksum "Cargo.lock" }}
24
- paths :
25
- - target
26
- - ~/.cargo/registry/cache
40
+ - *SAVE_DEPS
You can’t perform that action at this time.
0 commit comments