How to participate in an open source project and receive money?

  • Tutorial
Hello Habrahabr!

Many development teams participate in contests and accelerators. Win prizes or receive funding.
What to do if you do not have time to board a passing train?

There are several options. One of them is to start your project and wait for it to take off, while wasting time creating code and advertising the project in contests, accelerators, negotiations with investors. If successful, it is necessary to find specialists to raise the infrastructure. A number of virtual or real servers for the site, programmers, databases, clients. As a result, many projects never fly to GitHub and other similar resources.

You can view a list of successful projects for which money is being paid today, choose the one that is more interesting to you personally and start receiving compensation for your work, albeit not much.

Here is a complete list of projects:
tip4commit.com/projects

Here is an additional one:
prime4commit.com/projects

For example, select an OpenBazaar project. It can be useful in every store. They pay well for him. The server side is there in python. The project is at an early stage, a group of programmers is still being formed and is just getting out of alpha.

We look at the details of the code generation process, right on the integration server:
travis-ci.org/OpenBazaar/OpenBazaar/builds/36072087

We notice that the project uses tests for code style and coverage. We can immediately see the statistics:
coveralls.io/builds/1249548

We see that the simple work of creating comment lines and editing styles is still enough. And the price of such work is not small.
Sometimes this is $ 1 for 1 fixed line of code.

tip4commit.com/github/OpenBazaar/OpenBazaar

Well, let's get acquainted with the content of the requirements for the code, which claims to be part of the project:
github.com/OpenBazaar/OpenBazaar/blob/master/CONTRIBUTING.md

Everything is pretty real. But there is no business for a large company in this. Since the price for one patch is still quite small, when compared with the salary of a programmer in a large and medium-sized company. A patch takes a little time, but it can take several hours, and sometimes days, to accept it.

There is a desire to optimize the work


For Python, you can use the Pylint statistical analysis tool. It is easy to use. You just need to type:

pylint <имя вашего модуля>.py

And we immediately see the lines that you should pay attention to correct errors, style changes, etc.

You can also use examples from this package to automatically parse code and add-ons. In this way, you can write a script that will independently add parameters to comments for coverage tests, and other serial changes. Here are examples of such scripts one , two , three .

In general, you can even organize a working group of programmers. Get a free virtual server: cloud.lab.fi-ware.org
This is a European project from Telefonica. I was calmly given IP addresses for free in this cloud.
For the first time, this is a pretty good solution. Later, you can move to something more independent.

You can start with free code analysis tools: pmccabe, memory tests (DUMA / DML / VALGRIND). For python, this is pylint.
Wikipedia has entire articles on similar tools .

If over time tools for work accumulate - tests, compilers, scripts, tools for static and dynamic code analysis, licenses for paid services Coverity, Klocwork, you can also look towards PVS-Studio. All this can be stored on such a cloud server.

Details of working with GitHub and practically used git commands, notOnce and not two have been described on Habr:

Approximately such interaction commands with GitHub

Copy Repository


git clone git: //github.com: username / OpenBazaar.git
cd OpenBazaar
git remote add upstream git: //github.com/OpenBazaar/OpenBazaar.git
git fetch upstream
git checkout -b feature # Creates a new branch called “feature ”And makes it active.

Now, do good (and let it be expressed in commits).

git push origin feature # Uploads changes in the current branch to origin to the feature branch

Compress several patches into one (respectively, they will pay only for one PR, but sometimes you have to do this at the request of the project author or owner)


git clone git: //github.com: username / OpenBazaar.git
cd OpenBazaar
git remote add upstream git: //github.com/OpenBazaar/OpenBazaar.git
git fetch upstream
git checkout feature
git rebase -i master

= squash = - В at this point a window with a text file will open. If you replace the first word in the line with squash, then after writing the file, the patch of this line will be combined with the previous one (if squash is not there). Thus, several patches can be combined into one.

git push -f origin feature

Automatic synchronization with the main repository


git checkout master
git remote add upstream git: //github.com/OpenBazaar/OpenBazaar.git
git pull --rebase upstream master
git checkout feature
git rebase master

= fix any conflicts = - Open the files that git says in a text editor. Find the string '<<<' and merge the parts from 2 files into one.

git push -f origin feature



After that, the test is automatically launched on the repository (now it is compilation with the installation of dependencies and code style checking, but I would like to add static and dynamic analysis and automatic addition of comments with the description of arguments and return values).



Here is an example of transferring funds for errors found by the static analyzer:
tip4commit.com/projects/728/tips

Many thanks to all for your attention.
Link to the github code: github.com/OpenBazaar/OpenBazaar

Also popular now: