Gerrit » History » Version 6
neels, 05/12/2016 01:58 AM
1 | 1 | zecke | h1. Contributing using Gerrit |
---|---|---|---|
2 | |||
3 | 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 | |||
5 | h2. Subprojects using Gerrit |
||
6 | |||
7 | The following projects use Gerrit to contribute changes: |
||
8 | |||
9 | * libosmocore.git |
||
10 | * libosmo-abis.git |
||
11 | * libosmo-netif.git |
||
12 | 4 | zecke | * libosmo-sccp.git |
13 | 1 | zecke | * libsmpp34.git |
14 | * openbsc.git |
||
15 | * osmo-bts.git |
||
16 | * osmo-iuh.git |
||
17 | * osmo-pcu.git |
||
18 | * cellmgr-ng.git |
||
19 | 5 | zecke | * osmo-sip-connector.git |
20 | 1 | zecke | |
21 | h2. Configuring Gerrit/Account |
||
22 | |||
23 | 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 | |||
25 | * Pick a username (can not be changed) |
||
26 | * Add your public ssh key(s) |
||
27 | * Add email addresses you intend to use as author/comitter |
||
28 | |||
29 | h2. Setting up Gerrit for commits and pushing |
||
30 | |||
31 | 2 | zecke | * Add the remote to be able to fetch and push to gerrit |
32 | * Fetch the commit hook that adds Change-Id to each commit to uniquely identify a commit |
||
33 | |||
34 | <pre> |
||
35 | 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 | git push gerrit HEAD:refs/heads/user/topic (push a user branch) |
||
39 | git push gerrit HEAD:refs/heads/master (directly push to master if you are allowed to) |
||
40 | 6 | neels | git ls-remote gerrit changes/* (to list all changesets and patches) |
41 | 2 | zecke | </pre> |