From fee92fc1dd4480d9d5c72bd67243d3f6a9b03132 Mon Sep 17 00:00:00 2001 From: Jon Seymour Date: Thu, 4 Aug 2011 22:01:00 +1000 Subject: bisect: introduce support for --no-checkout option. If --no-checkout is specified, then the bisection process uses: git update-ref --no-deref HEAD at each trial instead of: git checkout Improved-by: Christian Couder Signed-off-by: Jon Seymour Signed-off-by: Junio C Hamano --- builtin/bisect--helper.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'builtin') diff --git a/builtin/bisect--helper.c b/builtin/bisect--helper.c index 5b226399e..8d325a517 100644 --- a/builtin/bisect--helper.c +++ b/builtin/bisect--helper.c @@ -4,16 +4,19 @@ #include "bisect.h" static const char * const git_bisect_helper_usage[] = { - "git bisect--helper --next-all", + "git bisect--helper --next-all [--no-checkout]", NULL }; int cmd_bisect__helper(int argc, const char **argv, const char *prefix) { int next_all = 0; + int no_checkout = 0; struct option options[] = { OPT_BOOLEAN(0, "next-all", &next_all, "perform 'git bisect next'"), + OPT_BOOLEAN(0, "no-checkout", &no_checkout, + "update BISECT_HEAD instead of checking out the current commit"), OPT_END() }; @@ -24,5 +27,5 @@ int cmd_bisect__helper(int argc, const char **argv, const char *prefix) usage_with_options(git_bisect_helper_usage, options); /* next-all */ - return bisect_next_all(prefix); + return bisect_next_all(prefix, no_checkout); } -- cgit v1.2.1