SourceTree - rebase --interactive - 合并冲突中止rebase

7
如果在交互式变基过程中出现合并冲突,我该如何使用SourceTree对另一个分支进行交互式变基呢?
我的观察:
我使用SourceTree进行交互式变基,通过右键单击要变基的分支,然后选择“交互式变基子项”来完成。
SourceTree会弹出“Interactive rebase from”对话框,允许我压缩提交等操作。无论我在这里指示SourceTree执行什么操作,如果我点击“确定”继续,SourceTree都会检测到合并冲突,如下所示:
git -c diff.mnemonicprefix=false -c core.quotepath=false -c sequence.editor='C:\Users\DNTRAINING\AppData\Local\SourceTree\app-2.3.5\tools\stree_gri' -c core.editor='C:\Users\DNTRAINING\AppData\Local\SourceTree\app-2.3.5\tools\stree_gri' rebase -i --autosquash 1b9102ed53ec63bd6d38a9436663bf58bda590b1
Auto-merging f3.txt
CONFLICT (content): Merge conflict in f3.txt
Rebasing (1/3)
error: could not apply af56da4... feature_rebase_test02 first attempt
Resolve all conflicts manually, mark them as resolved with
"git add/rm ", then run "git rebase --continue".
You can instead skip this commit: run "git rebase --skip".
To abort and get back to the state before "git rebase", run "git rebase --abort".
Could not apply af56da4... feature_rebase_test02 first attempt
Completed with errors, see above.
但是,它不允许我解决冲突,而只是中止了变基命令,回到了最初的状态。
那么,如果我还需要解决合并冲突,该如何在SourceTree中进行交互式变基呢?
谢谢, Klaus

我建议使用终端,因为rebase操作尚未被中止。 - evolutionxbox
1个回答

11

解决方案

  1. 不要点击消息对话框上的 关闭 按钮。 通过右键单击任务栏按钮并选择关闭来关闭 SourceTree

  2. 重新打开 SourceTree,解决冲突并提交。(需要手动输入提交消息 - 另一个 bug。)

  3. 单击 操作 > 继续变基

(对于其他冲突,请重复执行 1-3 步骤)

原因

这种行为可归因于此开放的 SourceTree bug:

https://jira.atlassian.com/browse/SRCTREEWIN-2493

(有两个以2715、2912结尾的重复 bug)


非常感谢。这个解决方案真的很有效。很遗憾这个问题还没有被修复。 - Jekyll

网页内容由stack overflow 提供, 点击上面的
可以查看英文原文,
原文链接