| 561 | } |
| 562 | |
| 563 | static int run_status(FILE *fp, const char *index_file, const char *prefix, int nowarn, |
| 564 | struct wt_status *s) |
| 565 | { |
| 566 | struct object_id oid; |
| 567 | |
| 568 | if (s->relative_paths) |
| 569 | s->prefix = prefix; |
| 570 | |
| 571 | if (amend) { |
| 572 | s->amend = 1; |
| 573 | s->reference = "HEAD^1"; |
| 574 | } |
| 575 | s->verbose = verbose; |
| 576 | s->index_file = index_file; |
| 577 | s->fp = fp; |
| 578 | s->nowarn = nowarn; |
| 579 | s->is_initial = repo_get_oid(the_repository, s->reference, &oid) ? 1 : 0; |
| 580 | if (!s->is_initial) |
| 581 | oidcpy(&s->oid_commit, &oid); |
| 582 | s->status_format = status_format; |
| 583 | s->ignore_submodule_arg = ignore_submodule_arg; |
| 584 | |
| 585 | wt_status_collect(s); |
| 586 | wt_status_print(s); |
| 587 | wt_status_collect_free_buffers(s); |
| 588 | |
| 589 | return s->committable; |
| 590 | } |
| 591 | |
| 592 | static int is_a_merge(const struct commit *current_head) |
| 593 | { |
no test coverage detected