Skip to end of metadata
Go to start of metadata
You are viewing an old version of this page. View the current version. Compare with Current  |   View Page History

Initial Setup

First, make sure you know the email address associated with your JIRA credentials. All commits pushed to the master repository are checked against these addresses, so your repository will need to be configured to use that address. The following will give you that information:

  • Visit the ZF Crowd install:
  • Log in, if you aren't.
  • Find the "My Profile" link in the upper right of the page, and follow it.
  • The resulting page will display your profile, including the email address with which you are registered. Make a note of it.
Windows Users
If you use Windows, and are unfamiliar with using Git or using Git on Windows, we recommend reading the illustrated guide to git on windows.

Setup your own public repository

Your next step is to establish a public repository from which we can pull your work into the master repository. You have two options: use github or other public site, or setup/use your own repository.

Option 1: GitHub

  • Setup a GitHub account, if you haven't yet
  • Fork the ZF2 respository
  • Clone your fork locally and enter it (use your own GitHub username in the statement below)
  • Configure git to use the email address with which you are registered in JIRA:
  • Add a remote to the canonical ZF repository (or GitHub mirror), so you can keep your fork up-to-date:

Option 2: Personal Repository

We assume you will use gitosis or gitolite to host your own repository. If you go this route, we will assume you have the knowledge to do so, or know where to obtain it. We will not assist you in setting up such a repository.

  • Create a new repository
  • Configure git to use the email address with which you are registered in JIRA:
  • Add an "origin" remote pointing to your gitosis/gitolite repo:
  • Add a remote for the ZF repository and fetch it
  • Create a new branch for the ZF repository (named "zf/master" here)
  • Create your master branch off the ZF branch, and push to your repository

Keeping Up-to-Date

Periodically, you should update your fork or personal repository to match the canonical ZF repository. In each of the above setups, we have added a remote to the Zend Framework repository, which allows you to do the following:

Working on Zend Framework

When working on Zend Framework, we recommend you do each new feature or bugfix in a new branch. This simplifies the task of code review as well as of merging your changes into the canonical repository.

A typical work flow will then consist of the following:

  • Create a new local branch based off your master branch.
  • Switch to your new local branch. (This step can be combined with the previous step with the use of `git checkout -b`.)
  • Do some work, commit, repeat as necessary.
  • Push the local branch to your remote repository.
  • Send a pull request.

The mechanics of this process are actually quite trivial. Below, we will create a branch for fixing an issue in the tracker.

To send a pull request, you have two options.

If using GitHub, you can do the pull request from there. Navigate to your repository, select the branch you just created, and then select the "Pull Request" button in the upper right. Select the user "zendframework" as the recipient.

If using your own repository - or even if using GitHub - you can send an email indicating you have changes to pull:

  • Send to
  • In your message, specify:
    • The URL to your repository (e.g., "git://")
    • The branch containing the changes you want pulled (e.g., "zf9295")
    • The nature of the changes (e.g., "implements Zend_Service_Twitter", "fixes ZF-9295", etc.)

Branch Cleanup

As you might imagine, if you are a frequent contributor, you'll start to get a ton of branches both locally and on your remote.

Once you know that your changes have been accepted to the master repository, we suggest doing some cleanup of these branches.

  • Local branch cleanup
  • Remote branch removal

Feeds and Emails

RSS feeds may be found at:

where <branch> is a branch in the repository.

To subscribe to git email notifications, send an email to:

You will need to reply to the verification email sent to you by this list.

Should you wish to filter emails from the list, they will use the "subject" line of commit messages, preceded by "[branch] ", and come from "".

Enter labels to add to this page:
Please wait 
Looking for a label? Just start typing.