gerrit - git gerrit - Merging straight to master in gerrit - gerrit code review
- If you want to make a change that you want to merge with master, the best way is to first create a topic branch
git checkout -b foo
Clicking "Copy Code" button will copy the code into the clipboard - memory. Please paste(Ctrl+V) it in your destination. The code will get pasted. Happy coding from Wikitechy - gerrit tutorial - git gerrit - google gerrit - team
- make a single commit with your feature
git commit -m "Made the thing X finally work"
Clicking "Copy Code" button will copy the code into the clipboard - memory. Please paste(Ctrl+V) it in your destination. The code will get pasted. Happy coding from Wikitechy - gerrit tutorial - git gerrit - google gerrit - team
- and push that branch to review via
git push origin foo:refs/for/master/foo
Clicking "Copy Code" button will copy the code into the clipboard - memory. Please paste(Ctrl+V) it in your destination. The code will get pasted. Happy coding from Wikitechy - gerrit tutorial - git gerrit - google gerrit - team
- Avoid working directly on master, as you will have problems resolving conflicts if someone else pushed to master before you. If you have your work on a separate branch, then resolving conflicts is as simple as
git checkout master
git pull origin master
git checkout foo
git rebase master
git push origin foo:refs/for/master/foo