-
-
Notifications
You must be signed in to change notification settings - Fork 43
[archived] Gerrit: setup with explanations
Matthieu Baerts edited this page Jul 14, 2019
·
1 revision
Note: Now that the new architecture code has been added in our repo, we are back to the patches sent via e-mails, with short iterations.
You now need to clone the Git repo with a Git Hook and optionally write a .gitreview
file:
- You can clone the repo using HTTP
git clone https://review.gerrithub.io/multipath-tcp/mptcp_net-next
but if you want to contribute, you will prefer having the SSH access:
git clone ssh://<YOUR GITHUB NICKNAME>@review.gerrithub.io:29418/multipath-tcp/mptcp_net-next
- You now need to get a Git Hook to automatically add a
Change-Id:
line in your commit. It is used by Gerrit to identify a patch: if you send a new version of your patch, the SHA will be different but this ID in the commit message will help Gerrit to know that it is a new version of an existing patch.
scp -p -P 29418 <YOUR GITHUB NICKNAME>@review.gerrithub.io:hooks/commit-msg mptcp_net-next/.git/hooks/
-
Note that you can get one command to do the
git clone
and get the Git Hook by looking at this page: https://review.gerrithub.io/admin/projects/multipath-tcp/mptcp_net-next -
(optional) it can be interesting to install and setup git-review tool to easily send/download patches to/from Gerrit. The setup is easy, use
git review -s
or:- Write your Github nickname in your
.git/config
:git config --local --add gitreview.username <YOUR GITHUB NICKNAME>
- At the root folder of your Git project, you can add a
.gitreview
file containing:
- Write your Github nickname in your
[gerrit]
host=review.gerrithub.io
port=29418
project=multipath-tcp/mptcp_net-next
defaultbranch=for-review
That's it!