@@ -38,6 +38,14 @@ pub struct Commit {
38
38
/// however, it does limit the amount of commits somewhat.
39
39
const EPOCH_COMMIT : & str = "927c55d86b0be44337f37cf5b0a76fb8ba86e06c" ;
40
40
41
+ const REPORT_HEADER : & str = "\
42
+ ==================================================================================
43
+ = Please file this regression report on the rust-lang/rust GitHub repository =
44
+ = New issue: https://github.com/rust-lang/rust/issues/new =
45
+ = Known issues: https://github.com/rust-lang/rust/issues =
46
+ = Copy and paste the text below into the issue report thread. Thanks! =
47
+ ==================================================================================" ;
48
+
41
49
#[ derive( Debug , StructOpt ) ]
42
50
#[ structopt( after_help = "EXAMPLES:
43
51
Run a fully automatic nightly bisect doing `cargo check`:
@@ -682,12 +690,12 @@ fn print_results(cfg: &Config, client: &Client, bisection_result: &BisectionResu
682
690
}
683
691
684
692
let tc_found = format ! ( "Regression in {}" , toolchains[ * found] ) ;
685
- eprintln ! ( "" ) ;
686
- eprintln ! ( "" ) ;
693
+ eprintln ! ( ) ;
694
+ eprintln ! ( ) ;
687
695
eprintln ! ( "{}" , "*" . repeat( 80 ) . dimmed( ) . bold( ) ) ;
688
696
eprintln ! ( "{}" , tc_found. red( ) ) ;
689
697
eprintln ! ( "{}" , "*" . repeat( 80 ) . dimmed( ) . bold( ) ) ;
690
- eprintln ! ( "" ) ;
698
+ eprintln ! ( ) ;
691
699
}
692
700
693
701
fn print_final_report (
@@ -707,20 +715,8 @@ fn print_final_report(
707
715
..
708
716
} = ci_bisection_result;
709
717
710
- #[ rustfmt:: skip]
711
- eprintln ! ( "{}" , "==================================================================================" . dimmed( ) ) ;
712
- #[ rustfmt:: skip]
713
- eprintln ! ( "{}" , "= Please file this regression report on the rust-lang/rust GitHub repository =" . dimmed( ) ) ;
714
- #[ rustfmt:: skip]
715
- eprintln ! ( "{}" , "= New issue: https://github.com/rust-lang/rust/issues/new =" . dimmed( ) ) ;
716
- #[ rustfmt:: skip]
717
- eprintln ! ( "{}" , "= Known issues: https://github.com/rust-lang/rust/issues =" . dimmed( ) ) ;
718
- #[ rustfmt:: skip]
719
- eprintln ! ( "{}" , "= Copy and paste the text below into the issue report thread. Thanks! =" . dimmed( ) ) ;
720
- #[ rustfmt:: skip]
721
- eprintln ! ( "{}" , "==================================================================================" . dimmed( ) ) ;
722
-
723
- eprintln ! ( "" ) ;
718
+ eprintln ! ( "{}" , REPORT_HEADER . dimmed( ) ) ;
719
+ eprintln ! ( ) ;
724
720
725
721
let ( start, end) = searched_range ( cfg, nightly_toolchains) ;
726
722
@@ -729,7 +725,7 @@ fn print_final_report(
729
725
eprintln ! ( "regressed nightly: {}" , nightly_toolchains[ * nightly_found] , ) ;
730
726
731
727
eprintln ! (
732
- "searched commits: from https://github.com/rust-lang/rust/commit/{} to https://github.com/rust-lang/rust/commit/{1}" ,
728
+ "searched commits: from https://github.com/rust-lang/rust/commit/{0 } to https://github.com/rust-lang/rust/commit/{1}" ,
733
729
ci_toolchains. first( ) . unwrap( ) ,
734
730
ci_toolchains. last( ) . unwrap( ) ,
735
731
) ;
@@ -739,15 +735,15 @@ fn print_final_report(
739
735
ci_toolchains[ * ci_found] ,
740
736
) ;
741
737
742
- eprintln ! ( "" ) ;
738
+ eprintln ! ( ) ;
743
739
eprintln ! ( "<details>" ) ;
744
740
eprintln ! (
745
741
"<summary>bisected with <a href='{}'>cargo-bisect-rustc</a> v{}</summary>" ,
746
742
env!( "CARGO_PKG_REPOSITORY" ) ,
747
743
env!( "CARGO_PKG_VERSION" ) ,
748
744
) ;
749
- eprintln ! ( "" ) ;
750
- eprintln ! ( "" ) ;
745
+ eprintln ! ( ) ;
746
+ eprintln ! ( ) ;
751
747
if let Some ( host) = option_env ! ( "HOST" ) {
752
748
eprintln ! ( "Host triple: {}" , host) ;
753
749
}
@@ -760,7 +756,7 @@ fn print_final_report(
760
756
eprint ! ( "{} " , arg. to_string_lossy( ) ) ;
761
757
}
762
758
}
763
- eprintln ! ( "" ) ;
759
+ eprintln ! ( ) ;
764
760
eprintln ! ( "```" ) ;
765
761
eprintln ! ( "</details>" ) ;
766
762
}
@@ -1149,7 +1145,7 @@ fn bisect_ci_in_commits(
1149
1145
1150
1146
if commits. is_empty ( ) {
1151
1147
bail ! (
1152
- "no commits between {} and {} within last 167 days" ,
1148
+ "no CI builds available between {} and {} within last 167 days" ,
1153
1149
start,
1154
1150
end
1155
1151
) ;
@@ -1162,7 +1158,7 @@ fn bisect_ci_in_commits(
1162
1158
}
1163
1159
1164
1160
eprintln ! ( "validated commits found, specifying toolchains" ) ;
1165
- eprintln ! ( "" ) ;
1161
+ eprintln ! ( ) ;
1166
1162
1167
1163
let toolchains = commits
1168
1164
. into_iter ( )
0 commit comments