@@ -21,11 +21,12 @@ jobs:
2121 fetch-depth : 1
2222
2323 - name : Install toolchain
24- uses : actions-rs/toolchain@v1
25- with :
26- toolchain : 1.75.0
27- override : true
28- components : rustfmt, clippy
24+ run : |
25+ rustup install $RUST_TOOLCHAIN_VERSION
26+ rustup default $RUST_TOOLCHAIN_VERSION
27+ rustup component add --toolchain $RUST_TOOLCHAIN_VERSION rustfmt clippy
28+ env :
29+ RUST_TOOLCHAIN_VERSION : 1.75.0
2930
3031 - uses : Swatinem/rust-cache@v2
3132 with :
@@ -77,11 +78,14 @@ jobs:
7778 with :
7879 fetch-depth : 1
7980
80- - name : Install latest beta
81- uses : actions-rs/toolchain@v1
82- with :
83- toolchain : beta
84- override : true
81+ - name : Install latest beta toolchain
82+ run : |
83+ rustup install %RUST_TOOLCHAIN_VERSION%
84+ rustup default %RUST_TOOLCHAIN_VERSION%
85+ rustup component add --toolchain %RUST_TOOLCHAIN_VERSION% rustfmt clippy
86+ env :
87+ RUST_TOOLCHAIN_VERSION : beta
88+ shell : cmd
8589
8690 - uses : Swatinem/rust-cache@v2
8791 with :
9094 - name : cargo check
9195 run : cargo check
9296 env :
93- RUSTFLAGS : -Dwarnings
97+ RUSTFLAGS : -Dwarnings
9498
9599 - name : Run unit tests
96100 run : cargo test --all
@@ -125,11 +129,13 @@ jobs:
125129 with :
126130 fetch-depth : 1
127131
128- - name : Install latest beta
129- uses : actions-rs/toolchain@v1
130- with :
131- toolchain : beta
132- override : true
132+ - name : Install latest beta toolchain
133+ run : |
134+ rustup install $RUST_TOOLCHAIN_VERSION
135+ rustup default $RUST_TOOLCHAIN_VERSION
136+ rustup component add --toolchain $RUST_TOOLCHAIN_VERSION rustfmt clippy
137+ env :
138+ RUST_TOOLCHAIN_VERSION : beta
133139
134140 - name : Configure environment
135141 run : |
@@ -162,11 +168,13 @@ jobs:
162168 with :
163169 fetch-depth : 1
164170
165- - name : Install latest beta
166- uses : actions-rs/toolchain@v1
167- with :
168- toolchain : beta
169- override : true
171+ - name : Install latest beta toolchain
172+ run : |
173+ rustup install $RUST_TOOLCHAIN_VERSION
174+ rustup default $RUST_TOOLCHAIN_VERSION
175+ rustup component add --toolchain $RUST_TOOLCHAIN_VERSION rustfmt clippy
176+ env :
177+ RUST_TOOLCHAIN_VERSION : beta
170178
171179 - name : Configure environment
172180 run : |
@@ -196,11 +204,13 @@ jobs:
196204 with :
197205 fetch-depth : 1
198206
199- - name : Install latest beta
200- uses : actions-rs/toolchain@v1
201- with :
202- toolchain : beta
203- override : true
207+ - name : Install latest beta toolchain
208+ run : |
209+ rustup install $RUST_TOOLCHAIN_VERSION
210+ rustup default $RUST_TOOLCHAIN_VERSION
211+ rustup component add --toolchain $RUST_TOOLCHAIN_VERSION rustfmt clippy
212+ env :
213+ RUST_TOOLCHAIN_VERSION : beta
204214
205215 - name : Configure environment
206216 run : |
@@ -227,11 +237,13 @@ jobs:
227237 with :
228238 fetch-depth : 1
229239
230- - name : Install latest beta
231- uses : actions-rs/toolchain@v1
232- with :
233- toolchain : beta
234- override : true
240+ - name : Install latest beta toolchain
241+ run : |
242+ rustup install $RUST_TOOLCHAIN_VERSION
243+ rustup default $RUST_TOOLCHAIN_VERSION
244+ rustup component add --toolchain $RUST_TOOLCHAIN_VERSION rustfmt clippy
245+ env :
246+ RUST_TOOLCHAIN_VERSION : beta
235247
236248 # We build a specific version of Valgrind because the one from the Ubuntu 22.04 repositories
237249 # has problems with Rust debuginfo.
@@ -294,10 +306,13 @@ jobs:
294306 - name : Check out repository code
295307 uses : actions/checkout@v2
296308
297- - name : Install stable
298- uses : actions-rs/toolchain@v1
299- with :
300- toolchain : stable
309+ - name : Install latest toolchain
310+ run : |
311+ rustup install $RUST_TOOLCHAIN_VERSION
312+ rustup default $RUST_TOOLCHAIN_VERSION
313+ rustup component add --toolchain $RUST_TOOLCHAIN_VERSION rustfmt clippy
314+ env :
315+ RUST_TOOLCHAIN_VERSION : stable
301316
302317 - uses : Swatinem/rust-cache@v2
303318
@@ -344,10 +359,13 @@ jobs:
344359 - name : Check out repository code
345360 uses : actions/checkout@v2
346361
347- - name : Install stable
348- uses : actions-rs/toolchain@v1
349- with :
350- toolchain : stable
362+ - name : Install latest stable toolchain
363+ run : |
364+ rustup install $RUST_TOOLCHAIN_VERSION
365+ rustup default $RUST_TOOLCHAIN_VERSION
366+ rustup component add --toolchain $RUST_TOOLCHAIN_VERSION rustfmt clippy
367+ env :
368+ RUST_TOOLCHAIN_VERSION : stable
351369
352370 - name : Install nightly
353371 run : rustup install nightly
0 commit comments