11
11
RUSTUP_MAX_RETRIES : 10
12
12
13
13
jobs :
14
- setup_cargo :
14
+ build_metrics :
15
15
if : github.repository == 'rust-lang/rust-analyzer'
16
16
runs-on : ubuntu-latest
17
+
17
18
steps :
18
19
- name : Install Rust toolchain
19
20
run : |
20
21
rustup update --no-self-update stable
21
22
rustup default stable
22
- rustup component add --toolchain stable rustfmt rust-src
23
-
24
- - name : Cache cargo
25
- uses : Swatinem/rust-cache@640a22190e7a783d4c409684cea558f081f92012
26
- with :
27
- key : ${{ runner.os }}-cargo-${{ github.sha }}
28
- cache-targets : " false"
23
+ rustup component add --toolchain stable rust-src
29
24
30
- build_metrics :
31
- runs-on : ubuntu-latest
32
- needs : setup_cargo
33
-
34
- steps :
35
25
- name : Checkout repository
36
26
uses : actions/checkout@v4
37
27
38
28
- name : Restore cargo cache
39
- uses : Swatinem/rust-cache@640a22190e7a783d4c409684cea558f081f92012
29
+ uses : Swatinem/rust-cache@9bdad043e88c75890e36ad3bbc8d27f0090dd609
40
30
with :
41
31
key : ${{ runner.os }}-cargo-${{ github.sha }}
42
32
cache-targets : " false"
45
35
run : cargo xtask metrics build
46
36
47
37
- name : Cache target
48
- uses : Swatinem/rust-cache@640a22190e7a783d4c409684cea558f081f92012
38
+ uses : Swatinem/rust-cache@9bdad043e88c75890e36ad3bbc8d27f0090dd609
49
39
with :
50
40
key : ${{ runner.os }}-cargo-${{ github.sha }}
51
41
cache-targets : " true"
@@ -62,14 +52,20 @@ jobs:
62
52
matrix :
63
53
names : [self, ripgrep-13.0.0, webrender-2022, diesel-1.4.8, hyper-0.14.18]
64
54
runs-on : ubuntu-latest
65
- needs : [setup_cargo, build_metrics]
55
+ needs : build_metrics
66
56
67
57
steps :
58
+ - name : Install Rust toolchain
59
+ run : |
60
+ rustup update --no-self-update stable
61
+ rustup default stable
62
+ rustup component add --toolchain stable rust-src
63
+
68
64
- name : Checkout repository
69
65
uses : actions/checkout@v4
70
66
71
67
- name : Restore cargo cache
72
- uses : Swatinem/rust-cache@640a22190e7a783d4c409684cea558f081f92012
68
+ uses : Swatinem/rust-cache@9bdad043e88c75890e36ad3bbc8d27f0090dd609
73
69
with :
74
70
key : ${{ runner.os }}-cargo-${{ github.sha }}
75
71
cache-targets : " true"
0 commit comments