What is the default behaviour of “Resolve using theirs” in git
As per this question, I know it is possible to keep all changes that did not raise any conflict, while using
theirchanges for the conflicting changes.
What I would like to know is, when using SourceTree (or, if relevant, any git tool or even the command line), what is the default behaviour when choosing
Resolve using theirson a single file (or even the complete merge).
- Does it simply replace the complete local file with whatever is in the remote ?
- Does it keep all the local non conflicting changes and only use
theirsfor all the conflicts?
One Solution collect form web for “What is the default behaviour of “Resolve using theirs” in git”
It resolves the non conflicting changes and prefers
theirs for conflicting ones. (The opposite for
ours >>> This option forces conflicting hunks to be auto-resolved cleanly by >>> favoring our version. Changes from the other tree that do not >>> conflict with our side are reflected to the merge result. This should not be confused with the ours merge strategy, which does not even look at what the other tree contains at all. It discards everything the other tree did, declaring our history contains all that happened in it. theirs This is opposite of ours.