Overview
Creating an Account
- Sign up through signup.asterisk.org
- Sign a CLA
- Go to Gerrit
- Click Sign In
- Sign in through openid.asterisk.org
- Profit
Setting up your Gerrit Account
- Add an SSH key
- Set your username
Cloning from Gerrit
SSH:
git clone ssh://{user}@{server}:29418/{repo}
HTTP:
git clone http://{user}@{server}/{repo}
Anonymous HTTP:
git clone http://{server}/{repo}
Pushing to Gerrit
How to push:
$ git push ssh://{username}@{server}:29418/{repo} HEAD:/refs/for/master
- Change-ID: Make sure you install the hook, if it isn't already there!
Installing it:
scp -p -P 29418 {username}@{server}:hooks/commit-msg {local-repo}/.git/hooks/
Fixing it if you forgot:
git commit -amend
Updating a Review
- Make sure any new commits use the same Change ID
Squash your commits back down into one (preferably)
git rebase -i HEAD~{num}
- Re-push