git fetch [email protected]:mediaTek/8127.git master_mlc
git cherry-pick ea196a1c06ab4afe9ee49f06751e4c73c38b95e8(master_mlc上面的提交)
出现冲突:
error: could not apply ea196a... *****
hint: after resolving the conflicts, mark the corrected paths
hint: with ‘git add ‘ or ‘git rm ‘
hint: and commit the result with ‘git commit‘
然后git status,发现一个Unmerged paths:
both modified: src/conflictsfile.mk
然后执行:git mergetool
默认选择vimdiff,回车进入:
眼花缭乱,我不在此修改,q命令依次退出这几个窗口。会询问我们冲突是否已经解决:
src/conflictsfile.mk seems unchanged. Was the merge successful?[y/n]
输入y回车,然后git status发现冲突的文件已经添加:
Changes to be committed: modified: src/conflictsfile.mk
然后手动编辑冲突的文件,使其内容和master_mlc分支上的内容一致,
然后git add此文件,最后执行git cherry-pick –continue即可。
———(注:git rebase 出现的冲突解决方法与此一致,最后的命令是:git rebase –continue)
时间: 2024-10-24 19:20:22