This Confluence has been LDAP enabled, if you are an ASF Committer, please use your LDAP Credentials to login. Any problems file an INFRA jira ticket please.

Child pages
  • Usergrid Committers Guide
Skip to end of metadata
Go to start of metadata

The Git repositories   

The official and canonical Usergrid Git repository is hosted in the ASF infrastructure, but there is also a mirror in Github:



The main and official repositories, Usergrid committers have write-access


Read-only mirror of the ASF repo. You can submit Pull Requests (PRs) but no write-access allowed.

Rules of thumb

  1. Every contribution is a piece of intellectual property. This is the precious sustenance that nourishes our project. Please treat it with respect. If it's sufficiently complex, or from a large corporate entity, ensure there is an ICLA or CCLA on file that covers the contribution. Asking in #usergrid or #asf will probably be the easiest way to get an answer. 

  2. ALWAYS give credit where it is due, ensure EVERY merged commit reflects properly the individual who authored that commit. Preserve both the name and email address. 
  3. Ensure your name and email address are there as the committer prior to pushing it to the Apache repositories. Please read the 'which hat' guide before deciding whether to use your, personal or other email address. 

  4. Always strive for linear commit history, avoid merge commits while pulling in contributor's changes.   

Committing the changes to the ASF repo

From a GitHub pull request   

      1. Clone the canonical ASF repo 

      git clone
      cd usergrid

      2.  Fetch the branch of the user you want to merge from  

             git fetch branch-to-merge-from 
    • If you commonly merge from a particular user, you'll want to add their repo as a remote to make fetching branches easier.       
         git remote add user-to-merge-from
         git fetch user-to-merge-from
    • Alternatively, you can configure a github remote to also fetch the pull requests, and checkout them as follows (for a complete guide refer to the GitHub howto):                             

         $ git remote add github
         $ vim .git/config
         # Edit the 'github' remote and add the additional 'fetch' line as follows
         [remote "github"]
              url =
              fetch = +refs/heads/*:refs/remotes/github/*
              fetch = +refs/pull/*/head:refs/remotes/github/pr/*
         # Now when fetching you will see all the pull requests (you can checkout them with "git checkout github/pr/99"):
         $ git fetch github
         * [new ref]         refs/pull/98/head -> github/pr/98
         * [new ref]         refs/pull/99/head -> github/pr/99
    3. Merge changes in from the PR branch, or cherry pick the specific commit you want to merge, for example:
            git cherry-pick hash-to-merge

         4.  Push the commit (you'll want to setup a .netrc file to make this easy, see  Committers: Getting Started )  

            git push


From a patch file

    1. Save the patch from the Github patch link (just append '.patch' to the pull request link to get it). This patch will keep the authorship of the commit, so we should use it instead of the diff. 

       If the commit message needs to be edited, edit it in the patch file. 

    2. Pull the changes in the ASF repository to make sure you have the latest version of the master branch. 

        git remote add asf   
        git fetch asf   
        git checkout master   
        git rebase asf/master 

       Apply the patch preserving the original author: 

        git am usergrid-XX.patch

    3. Run a build to make sure everything works as expected after applying the patch and push the changes once the build succeeds. 

        mvn clean install   
        git push asf master

    4. If there are no issues with the applied patch, attach the patch file to the JIRA issue, and mark it as Resolved. 

    5. Close the pull request and leave a comment saying it has been merged.


  • No labels