sourcetree - 如何快速解决多个合并冲突并使用主代码?

sourcetree - how to quickly resolve multiple merge conflicts and use master code?

我需要将我的 master 分支与我的开发分支合并,但是有太多的冲突,因为我一直在处理 master 而没有更新开发分支。

有没有快速解决这些问题的方法?我只是希望我的开发分支成为 master 的副本,我不太在意保留提交等,但无法删除开发分支并重新开始。

我考虑过做一个变基,但会遇到同样的冲突问题。

UDATE**

灾难!!现在由于所有冲突,我无法切换回 master 分支。我曾尝试隐藏合并,但出现错误。所以我然后使用 'Discard' 按钮并放弃了文件更改,希望这会回到原来的状态但是现在当我尝试结帐 master 时我收到错误消息,“以下未跟踪的工作树文件将被结帐覆盖:".

谁能帮帮我?首先,我需要能够切换到 master。忘记合并!

Disaster!! Now I am unable to switch back to the master branch because of all the conflicts. I have tried stashing the merge but that gave an error. So I then used the 'Discard' button and discarded the file changes hoping this would go back to how it was but now when I try to checkout master I get the error, "The following untracked working tree files would be overwritten by checkout:". I'm in a pickle!! :(

运行 git merge --abort 让自己回到冲突出现之前的状态。

I simply want my development branch to be a copy of the master and am not too fussed about keeping the commits etc.

如果您不担心保留提交,您可以将 master 中的文件复制到一个临时位置,检出 development 然后将临时目录的内容粘贴到您的存储库中工作区?