Mik*_*ler 8 merge xcode merge-conflict-resolution git-merge-conflict xcode10
我正处于变基中,我需要修复一些合并冲突。当我在 XCode 中打开文件时,我看到文件中的源代码控制冲突标记(<<<<<<< 等)。
如何使用 XCode 的合并工具以图形方式解决这些冲突?我正在寻找这个屏幕:
Jas*_*don 16
从这里拉出答案
# Tell system where Xcode utilities live:
sudo xcode-select -switch /Applications/Xcode.app/Contents/Developer
# Set "opendiff" as the default mergetool globally:
git config --global merge.tool opendiff
Run Code Online (Sandbox Code Playgroud)
然后,当git
告诉您存在冲突时,您可以运行git mergetool
它并打开 XCode 的合并工具(如问题的屏幕截图所示),您可以解决冲突。
FileMerge 工具是一个单独的应用程序,您可以从 Xcode 菜单中打开它: