有什麼複雜的: 我想複製最後提交從「dev」分支到「主」分支。從一個分支git副本提交到另一個
我這樣做
git checkout master
git cherry-pick a6b9463bec0a5240f6e945fbf4951c932751f28d
,我得到一個錯誤:
git cherry-pick a6b9463bec0a5240f6e945fbf4951c932751f28d
error: could not apply a6b9463... releasing v1.00
hint: after resolving the conflicts, mark the corrected paths
hint: with 'git add <paths>' or 'git rm <paths>'
hint: and commit the result with 'git commit'
git status
給
$ git status
# On branch master
# You are currently cherry-picking.
# (fix conflicts and run "git commit")
#
# Unmerged paths:
# (use "git add <file>..." to mark resolution)
#
# both modified: index.html
# both modified: js/boardDims.js
#
# Untracked files:
# (use "git add <file>..." to include in what will be committed)
#
# config.xml.orig
no changes added to commit (use "git add" and/or "git commit -a")
我不明白爲什麼它是複雜的複製COMIT到另一個分支。 你可以給我命令將這個提交複製到我的主分支嗎?
感謝
您是否嘗試解決衝突? (提示:'git mergetool') – dug 2014-10-28 20:18:33
是的,但我不明白是什麼彈出:有3個文件... – Louis 2014-10-28 20:21:12
不要把它看作3個文件,它基本上是一個文件在3個狀態(commit1,commit2 ,解決後) – 2014-10-28 20:22:16