I ran a git pull
that ended in a conflict. I resolved the conflict and everything is fine now (I used mergetool also).
When I commit the resolved file
If you just want to ditch the whole cherry-picking and commit files in whatever sets you want,
git reset --soft <ID-OF-THE-LAST-COMMIT>
gets you there.
What soft reset does is it moves the pointer pointing to current HEAD to the commit(ish) you gave but does not alter the files. Hard reset would move the pointer and also revert all files to the state in that commit(ish). This means with soft reset you can clear the merge status but keep the changes to actual files and then commit or reset them each individually per your liking.
For myself this happened in SourceTree when I tried to commit a merge before resolving all of the files. I then marked the last file resolved and yet it still gave me this error when trying to commit. I closed SourceTree and reopened it, and then it committed fine.
After reading all comments. this was my resolution:
I had to "Add" it again than commit:
$ git commit -i -m support.html "doit once for all" [master 18ea92e] support.html
git commit -am 'Conflicts resolved'
This worked for me. You can try this also.
Your merge stopped in the middle of the action. You should add your files, and then 'git commit':
git add file_1.php file_2.php file_3.php
git commit
Cheers
You can use git commit -i
for most cases but in case it doesn't work
You need to do git commit -m "your_merge_message"
. During a merge conflict you cannot merge one single file so you need to
git add your_file.txt
)git commit -m "your_merge_message"