Generally speaking, you want:
- Start the merger, but donβt commit the results. You want to execute the equivalent of
git merge --no-commit b . - Check the version of the file from the current branch (the version you want to keep).
- Add this to the index.
- Complete the merge.
This will result in a merge that does not affect the file. Unfortunately, there is no way in LibGit2Sharp not to transfer the result of the merge. This will be added to the 643 retrieval request .
source share