| 511 | } |
| 512 | |
| 513 | static int bisect_terms(struct bisect_terms *terms, const char *option) |
| 514 | { |
| 515 | if (get_terms(terms)) |
| 516 | return error(_("no terms defined")); |
| 517 | |
| 518 | if (!option) { |
| 519 | printf(_("Your current terms are '%s' for the old state\n" |
| 520 | "and '%s' for the new state.\n"), |
| 521 | terms->term_good, terms->term_bad); |
| 522 | return 0; |
| 523 | } |
| 524 | if (one_of(option, "--term-good", "--term-old", NULL)) |
| 525 | printf("%s\n", terms->term_good); |
| 526 | else if (one_of(option, "--term-bad", "--term-new", NULL)) |
| 527 | printf("%s\n", terms->term_bad); |
| 528 | else |
| 529 | return error(_("invalid argument %s for 'git bisect terms'.\n" |
| 530 | "Supported options are: " |
| 531 | "--term-good|--term-old and " |
| 532 | "--term-bad|--term-new."), option); |
| 533 | |
| 534 | return 0; |
| 535 | } |
| 536 | |
| 537 | static int bisect_append_log_quoted(const char **argv) |
| 538 | { |
no test coverage detected