| 6845 | } |
| 6846 | |
| 6847 | int sequencer_determine_whence(struct repository *r, enum commit_whence *whence) |
| 6848 | { |
| 6849 | if (refs_ref_exists(get_main_ref_store(r), "CHERRY_PICK_HEAD")) { |
| 6850 | struct object_id cherry_pick_head, rebase_head; |
| 6851 | |
| 6852 | if (file_exists(git_path_seq_dir())) |
| 6853 | *whence = FROM_CHERRY_PICK_MULTI; |
| 6854 | if (file_exists(rebase_path()) && |
| 6855 | !repo_get_oid(r, "REBASE_HEAD", &rebase_head) && |
| 6856 | !repo_get_oid(r, "CHERRY_PICK_HEAD", &cherry_pick_head) && |
| 6857 | oideq(&rebase_head, &cherry_pick_head)) |
| 6858 | *whence = FROM_REBASE_PICK; |
| 6859 | else |
| 6860 | *whence = FROM_CHERRY_PICK_SINGLE; |
| 6861 | |
| 6862 | return 1; |
| 6863 | } |
| 6864 | |
| 6865 | return 0; |
| 6866 | } |
| 6867 | |
| 6868 | int sequencer_get_update_refs_state(const char *wt_dir, |
| 6869 | struct string_list *refs) |
no test coverage detected