Auto resolve conflicts in smartgit while rebasing
Asked Answered
G

1

7

There is this nice feature in smartgit that sets the conflicted file as the rebase target, which is by invoking the command 'Set to rebase target ("theirs")' on the file.

However, I want this to be done automatically on every conflicted file during rebasing. There are just so many commits and conflicted files that resolving each file manually is very time consuming.

Is there a way to make smartgit perform that resolution automatically ?

Thanks.

Garek answered 22/11, 2014 at 18:58 Comment(0)
M
12

If smartgit is as smart as git then just go a head with

git rebase -s recursive -X theirs
Mete answered 22/11, 2014 at 19:7 Comment(5)
thanks, what command should I add if I were to rebase on 'upstream' ? something like git rebase upstream -s recursive -X theirs ?Garek
git rebase -s revursive -X theirs upstreamMete
I have my_branch that is set to track origin/dev. The status is that Your branch and 'origin/dev' have diverged, and have 41 and 200 different commits each. I executed the command git rebase -s recursive -X ours origin/dev but git stopped on a conflict. Why is that?Cabezon
Apparently, git automatically resolve conflicts only when the same file is modified in both branches. It does not resolve file deletions automaticallyCabezon
ours: the target-branch, theirs: the current-branch :sMaillol

© 2022 - 2024 — McMap. All rights reserved.