A small patch series (1, 2, 3) is worked on in the wip-key-inject-unless topic branch.
When running git review –yes, each commit is dispatched to the review designated by the Change-Id: of the message.
Continue reading “Working on a patch series with gerrit”
gerritexec is a command line tool listening to gerrit on a designated project. On each new patchset, it will:
- git clone the project
- git pull the patchset
- cd in the git tree and run a script
- positively review the patchset ( +1 ) if the program exit(0)
- negatively review the patchset ( -1 ) otherwise
For instance It can be used to run the integration tests found in the git tree of the stackforge/puppet-ceph project:
GEM_HOME=~/.gems gerritexec --hostname review.openstack.org \
--username puppetceph \
--script ' ( bundle install ; bundle exec rake spec:system ) > /tmp/out 2>&1 ; r=$? ; pastebinit /tmp/out ; exit $r #' \
Larger projects should consider using zuul or a gerrit jenkins plugin.
Continue reading “gerritexec: continuous integration one-liner”
The review and project management for Git based projects is installed on a virgin Debian GNU/Linux wheezy. Developers of l2mesh must submit patchs to the git repository to gerrit:
$ git review
remote: Resolving deltas: 100% (1/1)
remote: Processing changes: new: 1, done
* [new branch] HEAD -> refs/publish/master/master
Gerrit is bound to jenkins : it will run tests on the patch to be reviewed and let gerrit know if it succeeds. If a developer reviews the patch positively, it can be merged into the repository.
Continue reading “gerrit with jenkins : installation and configuration”