Skip to content
jayrambhia edited this page Apr 18, 2013 · 5 revisions

This is a brief guide for beginner developers who would like to contribute to SimpleCV. There are few basic steps that you need to follow to submit a successful pull request.

Step 1. Fork SimpleCV repository.

Go to SimpleCV Repository and click on Fork. Fork SimpleCV

Step 2. Clone your fork.

After successfully forking SimpleCV repository, you need to make a clone of your fork on your local machine.

git clone https://github.com/username/SimpleCV.git # Here username is your own github username

Step 3. Configure Remote.

After setting up the repository on your local machine, you need to configure your remote settings so as to be able to fetch regular updates and push your code.

cd SimpleCV
git remote add upstream https://github.com/sightmachine/SimpleCV.git

Now, you have added remote.

Make sure that you are in develop branch by git checkout develop

git fetch upstream
git merge upstream/develop

This will merge all the updates of SimpleCV repository to your local repository.

Contribution

After successfully forking and cloning SimpleCV repository, following steps would help you how to contribute to SimpleCV and send pull requests.

Step 4. Create a branch

Whenever you are working on some code, you must create a new branch and make changes in that branch so even if somehow things go wrong, you can revert back to your develop branch.

How to choose a branch name?

Branch name should be related to something that you are working on. Let's assume you are working on Machine Learning algorithms for SimpleCV, so you could keep your branch name as ML-module1.

git branch ML-module1
git checkout ML-module1

Now, you are in ML-module1 branch. You add files, change codes.

Step 5. Push your code

Sometimes it takes days to work on a particular code, but at the end of the day you might want to push your code to your clone.

git add filename1 filename2 filename3
# add all files that you changed.

git commit -m "ML module1 added"
# Keep a short commit message

git push origin ML-module1
# because your branch is ML-module1

Step 6. Send Pull Request.

If you feel that your code is working properly and is ready to be pushed in SimpleCV repository, you need to send a pull request. Go to your clone page on GitHub.

Change your branch to ML-Module1 using the drop down.

Chenge Branch


Click on Pull Request.

Pull Request


You will get a new page where you should write down about your pull request and explain about it in brief.

Pull Description


After that hit Send Pull Request.

Send Pull


Congrats! You have successfully send your first pull request to SimpleCV. Now, wait for them to review your request and merge your code.