I
I
Igor Deyashkin2014-01-23 18:03:42
git
Igor Deyashkin, 2014-01-23 18:03:42

How do you determine which commits are in conflict?

The situation is as follows:
There is a feature branch that forked from master a long time ago. There are quite a lot of commits in both master and feature (about a hundred in master, about 30 in feature). I am doing a rebase feature on master.
Naturally, conflicts arise. During their solution, I see only two states of the code:

  • code in master HEAD
  • the code in the feature commit, which is currently being rebased.

That is, it is clear which commit from feature conflicts with master, but it is not clear which commit from master.
And this can help a lot in resolving the conflict, since I can see what exactly has changed in one and the other commits.
I have to search the change log of the file I'm interested in, with my eyes, when this section of code changed, or look with git blame. The first one can be long if there are many commits. The second is if the file is large.
Are there any easier ways to find a conflicting commit in master?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
akashtrih, 2014-01-23
@akashtrih

It's not commits that conflict, but file changes. And yes, why rebase and not merge, which, in my opinion, is the best fit for this situation?

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question