Rules of Thumb

Setting up Your Repository

If you are a new committer, please see Git at Apache how to personalise git for easy committing.  If you are new to git, see the 'Quick git primer' section below.

Clone the canonical ASF repo using this command. The --origin option tells git to name the remote apache instead of the default, origin; this will reduce ambiguity when we later add a second remote upstream:

git clone https://git-wip-us.apache.org/repos/asf/incubator-corinthia.git <yourRepoName>

 

Merging from a patch file

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. Apply the patch preserving the original author:

cd <yourRepoName>
git co master

git pull

git apply foo.patch

git add -u

git commit -F ../your.logmessage

git push

Quick git primer for workflow

Assumes you have already cloned the git, and are going to start working on a patch.

Never work directly in master, every commit in master must be tested by running dftest.

In order to work, and have local commits (like "finished 1part, going out for lunch"), use the following recipe

 

 

cd <yourRepoName>
git co master
git pull
git branch -b work
<do all your work, including several small commits>
git commit -a -F ./your.logmessage
<continue working>
<run dtest to ensure all test case still work>
git co master
git merge --squash work
git commit -a -F ../your.logmessage
git push

Additional Information

Particularly for new committers, you may find the following information useful: