Introducing Gerrit - Code Review and Community Contributions
Posted by Marcus Hanwell in Software Process, Open Source. Viewed 3277 times.Hopefully you are all convinced by now that Git is both more powerful, and more complicated, than CVS or Subversion. We published an article in the October issue of the Source on our branch based Git workflow. Many of our open source projects have migrated to Git, such as CMake, VTK, ParaView and ITK. I was excited by another possibility distributed version control offers us - tightly integrated code review. Gerrit is a tool developed by some of the folks at Google, principally Shawn Pearce (interview here), to facilitate code review for the Android operating system and associated projects.
I first encountered Gerrit when developing Avogadro, one of the projects I develop in my spare time. I liked it so much I talked about it internally at Kitware, and set up a test server. Since then we have set up a public Gerrit server, primarily for the ITK community but with a view to try it out with other projects. One of the distinct advantages of distributed version control is that you can push your commits to multiple places, or remotes. Gerrit acts as an additional remote, somewhere you can push proposed patches and have them show up in the web interface. It has very tight integration with Git, allowing developers to set up accounts, and then push topic branches to the Gerrit remote if they wish to have their changes reviewed.
It also has another big advantage for us as an open source project. Anyone can sign up for a Gerrit account, add the remote and upload their topic branches. This allows us to accept contributions from members of our community much more easily, and to provide feedback on any issues with a proposed patch right in the web interface. We also get copy and paste lines to fetch proposed patches, so that I can have a full checkout of a submitted topic branch within seconds. Once you have an account set up you can select a username, upload your public SSH key and select the projects you would like to monitor in your settings (link in the top right of the page after you have signed in).
I would appreciate feedback from members of our open source communities as we work to make contributing to our projects easier.
