@matheusbsbs / matheus-bagliano / commits / c99f069de2
Fork 0

bisect--helper: remove "--next-vars" option as it is now useless

Because it has been replaced by "--next-exit". Signed-off-by: Christian Couder <chriscool@tuxfamily.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>

Christian Couder committed Apr 21, 2009 at 07:54 UTC c99f069de2f06b7abe0406c2ff1b46621dbc9398
3 files changed +3 -25
bisect.c
-15
@@ -554,21 +554,6 @@ static void bisect_common(struct rev_info *revs, const char *prefix,
554 !!skipped_sha1_nr);
555 }
556
557 -int bisect_next_vars(const char *prefix)
558 -{
559 - struct rev_info revs;
560 - struct rev_list_info info;
561 - int reaches = 0, all = 0;
562 -
563 - memset(&info, 0, sizeof(info));
564 - info.revs = &revs;
565 - info.bisect_show_flags = BISECT_SHOW_TRIED | BISECT_SHOW_STRINGED;
566 -
567 - bisect_common(&revs, prefix, &reaches, &all);
568 -
569 - return show_bisect_vars(&info, reaches, all);
570 -}
571 -
557 static void exit_if_skipped_commits(struct commit_list *tried,
558 const unsigned char *bad)
559 {
bisect.h
-1
@@ -28,7 +28,6 @@ struct rev_list_info {
28
29 extern int show_bisect_vars(struct rev_list_info *info, int reaches, int all);
30
31 -extern int bisect_next_vars(const char *prefix);
31 extern int bisect_next_exit(const char *prefix);
32
33 extern int estimate_bisect_steps(int all);
builtin-bisect--helper.c
+3 -9
@@ -4,18 +4,14 @@
4 #include "bisect.h"
5
6 static const char * const git_bisect_helper_usage[] = {
7 - "git bisect--helper --next-vars",
7 "git bisect--helper --next-exit",
8 NULL
9 };
10
11 int cmd_bisect__helper(int argc, const char **argv, const char *prefix)
12 {
14 - int next_vars = 0;
13 int next_exit = 0;
14 struct option options[] = {
17 - OPT_BOOLEAN(0, "next-vars", &next_vars,
18 - "output next bisect step variables"),
15 OPT_BOOLEAN(0, "next-exit", &next_exit,
16 "output bisect result and exit instuctions"),
17 OPT_END()
@@ -23,11 +19,9 @@ int cmd_bisect__helper(int argc, const char **argv, const char *prefix)
19
20 argc = parse_options(argc, argv, options, git_bisect_helper_usage, 0);
21
26 - if ((next_vars && next_exit) || (!next_vars && !next_exit))
22 + if (!next_exit)
23 usage_with_options(git_bisect_helper_usage, options);
24
29 - if (next_vars)
30 - return bisect_next_vars(prefix);
31 - else /* next-exit */
32 - return bisect_next_exit(prefix);
25 + /* next-exit */
26 + return bisect_next_exit(prefix);
27 }