@@ -167,9 +167,6 @@ impl Features {
167
167
168
168
impl std:: fmt:: Display for Features {
169
169
fn fmt ( & self , f : & mut std:: fmt:: Formatter < ' _ > ) -> std:: fmt:: Result {
170
- if & Self :: all_features ( ) == self {
171
- return write ! ( f, "all" ) ;
172
- }
173
170
for ( i, feature) in self . 0 . iter ( ) . sorted ( ) . enumerate ( ) {
174
171
if i > 0 {
175
172
write ! ( f, "," ) ?;
@@ -298,10 +295,14 @@ impl App {
298
295
CiMatrixRow {
299
296
command : self . clone ( ) . into_command_string ( ) . into_string ( ) . unwrap ( ) ,
300
297
name : format ! (
301
- "{}({}) - {}" ,
298
+ "{}({}) - {}" ,
302
299
self . subcmd. as_ref( ) ,
303
300
os,
304
- self . global_args. features
301
+ if self . global_args. features == Features :: all_features( ) {
302
+ "all features" . to_owned( )
303
+ } else {
304
+ self . global_args. features. to_string( )
305
+ }
305
306
) ,
306
307
os,
307
308
}
@@ -473,22 +474,25 @@ impl Xtasks {
473
474
// we don't need to verify all feature flags on all platforms, this is mostly a "does it compile" check
474
475
// for finding out missing compile time logic or bad imports
475
476
multi_os_steps
476
- . retain ( |e| !e. command . contains ( "build" ) && !e. command . contains ( "docs" ) ) ;
477
+ . retain ( |e| !e. command . contains ( " build" ) && !e. command . contains ( " docs" ) ) ;
477
478
478
479
let mut macos_matrix = multi_os_steps. clone ( ) ;
479
480
let mut windows_matrix = multi_os_steps. clone ( ) ;
480
481
481
482
for row in macos_matrix. iter_mut ( ) {
482
483
row. os = "macos-latest" . to_owned ( ) ;
484
+ row. name = row. name . replace ( "ubuntu-latest" , "macos-latest" ) ;
483
485
}
484
486
485
487
for row in windows_matrix. iter_mut ( ) {
486
488
row. os = "windows-latest" . to_owned ( ) ;
489
+ row. name = row. name . replace ( "ubuntu-latest" , "windows-latest" ) ;
487
490
}
488
491
489
492
matrix. extend ( macos_matrix) ;
490
493
matrix. extend ( windows_matrix) ;
491
494
495
+ matrix. sort_by_key ( |e| e. name . to_owned ( ) ) ;
492
496
let json = serde_json:: to_string_pretty ( & matrix) ?;
493
497
return Ok ( json) ;
494
498
}
0 commit comments