我想从上游仓库的分支中拉取更改。我已经使用以下命令设置了上游仓库:
git remote add upstream http://URL-of-master-repo.git
然后我尝试使用 pull
命令拉取更改。
git checkout my-local-branch
git fetch upstream remote-branch
git merge upstream/remote-branch
但是这些文件仍然没有出现在我的磁盘上,我却遇到了冲突:
Auto-merging minimal-build-config.cmake
CONFLICT (content): Merge conflict in minimal-build-config.cmake
Automatic merge failed; fix conflicts and then commit the result.
我该如何正确解决冲突,以便能够从上游分支获取文件?
git merge upstream/remote-branch
但只得到了Already up-to-date
。 - stdcerr