Project

General

Profile

Gerrit » History » Version 5

zecke, 05/09/2016 09:35 PM

1 1 zecke
h1. Contributing using Gerrit
2 1 zecke
3 1 zecke
Gerrit is a review tool that integrates nicely with git and ssh. Instead of manually uploading a change, one can push it for review. One can use ssh to trigger review and actions.
4 1 zecke
5 1 zecke
h2. Subprojects using Gerrit
6 1 zecke
7 1 zecke
The following projects use Gerrit to contribute changes:
8 1 zecke
9 1 zecke
* libosmocore.git
10 1 zecke
* libosmo-abis.git
11 1 zecke
* libosmo-netif.git
12 4 zecke
* libosmo-sccp.git
13 1 zecke
* libsmpp34.git
14 1 zecke
* openbsc.git
15 1 zecke
* osmo-bts.git
16 1 zecke
* osmo-iuh.git
17 1 zecke
* osmo-pcu.git
18 1 zecke
* cellmgr-ng.git
19 5 zecke
* osmo-sip-connector.git
20 1 zecke
 
21 1 zecke
h2. Configuring Gerrit/Account
22 1 zecke
23 1 zecke
You will need to sign-up at https://gerrit.osmocom.org/login/. If you have an Osmocom Redmine account you can use https://osmocom.org/openid as OpenID provider. After the initial sign-up you will need to:
24 1 zecke
25 1 zecke
* Pick a username (can not be changed)
26 1 zecke
* Add your public ssh key(s)
27 1 zecke
* Add email addresses you intend to use as author/comitter
28 1 zecke
29 1 zecke
h2. Setting up Gerrit for commits and pushing
30 1 zecke
31 2 zecke
* Add the remote to be able to fetch and push to gerrit
32 2 zecke
* Fetch the commit hook that adds Change-Id to each commit to uniquely identify a commit
33 2 zecke
34 2 zecke
<pre>
35 2 zecke
git remote add gerrit ssh://USERNAME@gerrit.osmocom.org:29418/PROJECT.git
36 3 zecke
scp -P 29418 USERNAME@gerrit.osmocom.org:hooks/commit-msg .git/hooks/
37 2 zecke
git push gerrit HEAD:refs/for/master (push for review)
38 2 zecke
git push gerrit HEAD:refs/heads/user/topic (push a user branch)
39 2 zecke
git push gerrit HEAD:refs/heads/master (directly push to master if you are allowed to)
40 2 zecke
git ls-remote gerrit (to list all changesets and patches)
41 2 zecke
</pre>
Add picture from clipboard (Maximum size: 48.8 MB)