Re: [PATCH 09/10] bisect: implement "read_bisect_paths" to read paths in "$GIT_DIR/BISECT_NAMES"
Christian Couder <chriscool@tuxfamily.org> writes:
Show 5 quoted lines
> This is needed because "git bisect--helper" must read bisect paths
> in "$GIT_DIR/BISECT_NAMES", so that a bisection can be performed only
> on commits that touches paths in this file.
>
> Signed-off-by: Christian Couder <chriscool@tuxfamily.org>
Show 24 quoted lines
> bisect.c | 56 +++++++++++++++++++++++++++++++++++++++++++++++---------
> 1 files changed, 47 insertions(+), 9 deletions(-)
>
> diff --git a/bisect.c b/bisect.c
> index ce62696..a6fd826 100644
> --- a/bisect.c
> +++ b/bisect.c
> @@ -4,6 +4,7 @@
> #include "revision.h"
> #include "refs.h"
> #include "list-objects.h"
> +#include "quote.h"
> #include "bisect.h"
>
>
> @@ -424,6 +425,33 @@ static int read_bisect_refs(void)
> return for_each_bisect_ref(register_ref, NULL);
> }
>
> +void read_bisect_paths()
> +{
> + struct strbuf str = STRBUF_INIT;
> + const char *filename = git_path("BISECT_NAMES");
> + FILE *fp = fp = fopen(filename, "r");