首页 > 其他 > 详细

git cherry-pick

时间:2015-04-13 22:45:50      阅读:388      评论:0      收藏:0      [点我收藏+]
将A分支上的某一次提交合并到B分支上。
实际问题:将Vendor分支commit:37213cf的修改合并到develop_4.4分支上。
 
fujun@CS-csmsi:~/amlogic_4.4/amlogics802$ git checkout develop_4.4
fujun@CS-csmsi:~/amlogic_4.4/amlogics802$ git cherry-pick 37213cf
 
a.如果顺利就正常提交
git add
git commit -m ""
 
b.如果有冲突,手动解决
fujun@CS-csmsi:~/amlogic_4.4/amlogics802$ git status
fujun@CS-csmsi:~/amlogic_4.4/amlogics802$ git add
fujun@CS-csmsi:~/amlogic_4.4/amlogics802$ git commit -m ""
# On branch develop_4.4
# Changes to be committed:
#
#       modified:   common/drivers/amlogic/amports/m8/ucode/encoder/h264_enc_mix_dump.h
#       modified:   common/drivers/amlogic/amports/m8/ucode/encoder/h264_enc_mix_dump_dblk.h
#       modified:   common/drivers/amlogic/amports/m8/ucode/encoder/h264_enc_mix_sw.h
#       modified:   common/drivers/amlogic/amports/m8/ucode/encoder/h264_enc_mix_sw_hdec_dblk.h
#       modified:   common/drivers/amlogic/amports/m8/ucode/encoder/h264_enc_mix_sw_vdec2_dblk.h
#       modified:   packages/amlogic/LibPlayer/amplayer/player/player.c
#
# Unmerged paths:
#   (use "git add/rm <file>..." as appropriate to mark resolution)
#
#       both modified:      packages/amlogic/LibPlayer/amadec/adec-ffmpeg-mgt.c

git cherry-pick

原文:http://www.cnblogs.com/black-mamba/p/4423439.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!