publish and submit

http://blog.csdn.net/w_jewelry/article/details/8123639

1.Gerrit里点击“publish and submit”提示如下:
Your change could not be merged due to a path conflict.
Please merge (or rebase) the change locally and upload the resolution for review.
2.解决方法如下:

1. cd ~/projects/pan #切换到pan项目
2. git branch #查看分支情况
3. git checkout master #选择分支
4. git fetch origin #fetch与pull的区别,自己再搜吧~
5. git rebase origin/master #查看有“CONFLICT (content): ”的地方,手工解决冲突后,下一步
6. git add dev/controller/web/index.php #这只是一个举例,即要先add操作
7. git rebase --continue
8. git push origin HEAD:refs/for/master #OK了

Git push后,你需要在Gerrit里面再次review一次。

3.本文参考博客:《Git,Gerrit,hudson(3)--git技巧总结》

原文地址:https://www.cnblogs.com/Ph-one/p/6496386.html