File tree Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Expand file tree Collapse file tree 1 file changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -171,7 +171,12 @@ impl RustwideBuilder {
171
171
}
172
172
// NOTE: rustup will automatically refuse to update the toolchain
173
173
// if `rustfmt` is not available in the newer version
174
- self . toolchain . add_component ( & self . workspace , "rustfmt" ) ?;
174
+ // NOTE: this ignores the error so that you can still run a build without rustfmt.
175
+ // This should only happen if you run a build for the first time when rustfmt isn't available.
176
+ if let Err ( err) = self . toolchain . add_component ( & self . workspace , "rustfmt" ) {
177
+ log:: warn!( "failed to install rustfmt: {}" , err) ;
178
+ log:: info!( "continuing anyway, since this must be the first build" ) ;
179
+ }
175
180
176
181
self . rustc_version = self . detect_rustc_version ( ) ?;
177
182
if old_version. as_deref ( ) != Some ( & self . rustc_version ) {
You can’t perform that action at this time.
0 commit comments