Solved : you have not concluded your merge (merge_head exists)

If you are getting an error "you have not concluded your merge (merge_head exists)" in the source tree(Git) while doing a pull request, the problem can be your previous pull failed to merge automatically.
There can be multiple scenarios in which you do face error "you have not concluded your merge (merge_head exists)". So there are numerous possibilities of the solution, depending on how you got there. 

You have not concluded your merge (MERGE_HEAD exists). Please, commit your changes before you can merge.
if you run command, git status you get below result.

nothing to commit (working directory clean)

Cause / Reason of Problem: Pull request failed to merge automatically.

Solution :
1.Undo the merge of Pull Request which was failed

Use Commands:
Git merge --abort (Command works on version 1.7.4 and higher)
Git reset --merge (Command works prior to version 1.7.4)
2.Now, Do pull request
3.If you get conflict, resolve it and Commit it
4.Take a pull again and it should work

Also Read : Error: unable to unlink old '$fileName': Invalid argument

There are numerous solutions available over Stack Overflow, Quora, etc sites about solving error message "you have not concluded your merge (merge_head exists)". But before you start taking any steps towards a solution, please first follow below mentioned steps.

1. Check if you have any uncommitted changes in "File Status", If you have then either stash it or Discard/Remove it after taking a backup from the physical location.

2. You might see a conflict of files with conflict comment in commit section, If these files are not relevant to your changes the simply remove the comment and discard the files.

Post a Comment