This page documents how to submit your changes to us for inclusion.
We manage the submission of patches using the
Gerrit code review tool. This tool
implements a workflow on top of the Git version
control system to ensure that all changes get peer reviewed and tested
prior to their distribution.
Create An Account
Browse to http://review.webmproject.org/ and complete the signup
process. You must register using OpenId.
OpenId provides secure single-sign-on, so you don’t need to create a
new account or remember another password. If you have a Google account
or a Yahoo ID, you’re all set. There are many other OpenID providers
available. You may already have an OpenID.
You will be required to execute a contributor agreement to
ensure that the WebM Project has the rights to distribute your
changes. Individuals can execute this agreement online. Corporations
must submit this agreement via mail or fax. OpenID provides secure
single-sign-on, without revealing your passwords to this website.
Create or Upload your SSH Public Key
You must have an SSH public key to upload changes to Gerrit. GitHub
has some good guides to creating these keys if you haven’t done this
before. This is just a guide — you don’t have to sign up for GitHub
to contribute to WebM.
Upload Your Change
Find the correct URL to push to on the main code
page and determine the branch you want your change to start on by
looking at our
repository layout. You can
set up your Git and SSH configurations to simplify this command line
quite a bit. See the Gerrit
for more information. The command you’ll use is of the general form:
$ git push ssh://email@example.com:29418/projectname HEAD:refs/for/branchname
If you previously uploaded a change to Gerrit and the Approver has
asked for changes, follow these steps:
- Edit the files to make the changes the Approver has requested.
- Recommit your edits using the
$ git commit -a --amend
- Use the same
git pushcommand as above to upload to Gerrit again
for another review cycle.
In general, you should not rebase your changes when doing updates in
response to review. Doing so can make it harder to follow the
evolution of your change in the diff view.
If your commit does not include a ‘Change-Id:’ line in its commit
message, you’ll have to add one. Do so by running
git commit to edit the commit message, and then create a
‘Change-Id: I …’ by using the ID number of the change you’re trying
to update, which can be found using the web UI.
Submitting your Change
Once your change has been Approved and Verified, you can “submit” it
through the Gerrit UI. This will usually automatically merge your
change into the branch you specified, creating a new merge commit in
Git if neccessary. Sometimes this can’t be done automatically. If you
run into this problem, you must rebase or merge your changes manually.
We strongly prefer that you rebase your changes instead of merging
them. To do so, run:
$ git fetch $ git rebase origin/branchname
If you get any conflicts, resolve them as you normally would with git.
When you’re done, reupload your change.
Viewing the status of uploaded changes
To check the status of a change that you uploaded, open Gerrit, sign
in, and click My > Changes.