Course lesson
Fix a Pull Request that has a Merge Conflict
If we try to make a pull request on github that has a conflict, there are a few ways to fix it.
- Duration
- 2 min
- Access
- Included
- Transcript
- Needs source
If we try to make a pull request on github that has a conflict, there are a few ways to fix it.
We're going to first back out of the pull request, and then merge master into our feature branch.
We'll manage the merge conflict locally, and then do a new pull request (which will not have the conflict)
git checkout -b conflicts_branch
# Add 'Line4' and 'Line5'
git commit -am "add line4 and line5"
git push origin conflicts_branch
git checkout master
# Add 'Line6' and 'Line7'`
git commit -am "add line6 and line7"
git push origin master