Rules of Thumb
- Every contribution is a piece of intellectual property. Please treat it with respect.
- Preserve both the name and email address. This is the precious sustenance that nourishes our project.
- Ensure your name and email address are there as the committer prior to pushing it to the Apache repositories.
- Always give credit where it is due, ensure every merged commit reflects properly the individual who authored that commit.
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.
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> |
---|
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 |
---|
dtest -plain
to ensure all test cases 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:
- Pro Git: Free book available as HTML and PDF. Also available in other languages, please see the HTML version for a list.
- Guide for new project committers
- Committers FAQ
- Git at Apache