GIT: discard local changes and commit after a merge/pull

git – How can I discard remote changes and mark a file as “resolved”? – Stack Overflow

git checkout has the –ours option to check out the version of the file that you had locally (as opposed to –theirs, which is the version that you pulled in). You can pass . to git checkout to tell it to check out everything in the tree. Then you need to mark the conflicts as resolved, which you can do with git add, and commit your work once done: