向openstack开发版本上传代码只需要在master分支上拉一个新的分支,修复之后上传。
向稳定版本修复bug则要从稳定版本拉出一个分支,以cinder grizzly版本为例,具体步骤如下:
1,更新本地库到最新:
git checkout master
git remote update
git pull origin master
2,从稳定版本拉出一个分支:
git checkout -b bug/xxxxxx remotes/origin stable/grizzly
3,修改文件
4,上传:
git add .
git commit -a -F .git\CMessage
git review stable/grizzly
CMessage 是对此次修改的说明,包括:
修改简介
具体说明
Closes-bug: xxxxxx
Change-Id: --------
有了这个文件每次提交信息就不用重复输入说明了。
参考:https://wiki.openstack.org/wiki/Documentation/HowTo#How_to_a_make_changes_to_a_stable_branch