Hi,

On 10/14/2016 04:14 PM, Pranit Bauva wrote:
> diff --git a/builtin/bisect--helper.c b/builtin/bisect--helper.c
> index 4254d61..d84ba86 100644
> --- a/builtin/bisect--helper.c
> +++ b/builtin/bisect--helper.c
> @@ -84,12 +89,47 @@ static int write_terms(const char *bad, const char *good)
>       return (res < 0) ? -1 : 0;
>  }
>  
> +static int bisect_reset(const char *commit)
> +{
> +     struct strbuf branch = STRBUF_INIT;
> +
> +     if (!commit) {
> +             if (strbuf_read_file(&branch, git_path_bisect_start(), 0) < 1) {
> +                     printf("We are not bisecting.\n");

I think this string should be marked for translation.

> +                     return 0;
> +             }
> +             strbuf_rtrim(&branch);
[...]
> @@ -121,6 +163,10 @@ int cmd_bisect__helper(int argc, const char **argv, 
> const char *prefix)
>               if (argc != 0)
>                       die(_("--bisect-clean-state requires no arguments"));
>               return bisect_clean_state();
> +     case BISECT_RESET:
> +             if (argc > 1)
> +                     die(_("--bisect-reset requires either zero or one 
> arguments"));

This error message is imho a little unspecific (but this might not be an
issue because bisect--helper commands are not really exposed to the
user). Maybe "--bisect-reset requires either no argument or a commit."?

> +             return bisect_reset(argc ? argv[0] : NULL);
>       default:
>               die("BUG: unknown subcommand '%d'", cmdmode);
>       }

~Stephan

Reply via email to