Resolve merge conflicts on GitHub
Merge conflict happens when two branches modify the same file and the same line of code. Git will not merge the branches automatically but displays the error message. We need to resolve all merge conflicts in order to merge a pull request successfully.
Simple merge conflicts can be resolved by using the Resolve conflicts button in the pull request.
Click on the Resolve conflicts button.
Manually resolve the merge conflict. Decide which code to retain and remove the unnecessary code changes.
Mark the conflict as Resolved by clicking the Mark as resolved button.
Click on the Commit merge button.
Now the Merge pull request button would be enabled.
Click on the Merge pull request to merge the changes and resolved conflicts.