Contributions to the Open Source community, Part 1 How to get started with GitHub projects
Hosting code on GitHub has a whole host of advantages. Especially in terms of collaboration and version control, the service is now almost indispensable in software development. But how is it possible to work on an existing project?
Company on topic
If you want to take your first steps at GitHub, you can participate in a project.
In modern software development in a team, version control is useful and practical. Where there are constant changes to the code base, it is important to know which code was added, modified or deleted where. Especially since in teams several developers work at the same time on the code base.
To manage these versions, there has been the version control system Git for quite some time, but its operation is quite complex and only works locally. For the simple hosting of code repositories, GitHub was therefore developed in 2008. A kind of Git cloud that any user can access. GitHub is now part of Microsoft.
Benefits for all projects
The big advantage of GitHub is that version control is moved to the cloud – making it easy to share projects. It doesn’t matter if they are open source or closed source projects. GitHub supports quickly adding developers to the team who can access the same code base – worldwide.
Developers can also “fork” the existing code base and then have it transferred to the main root via pull request, for example to play through an idea. For open source projects, forks are also used to create an alternative application or to revive an orphaned project. In short, Github is extremely convenient for software development.
Working on open source projects
Developers who don’t want to design projects from scratch, but prefer to try their hand at improving existing software or updating orphaned projects, will find a huge pool of existing solutions on GitHub. The first steps are very simple.
After creating a GitHub user account and installing Git on the computer, you can start. For example, GitHub itself offers an easy-to-use local desktop version of Git, where users only need to log in with the GitHub account. Alternatively, the” normal”, CLI-based Git can be installed.
Find and contribute to GitHub project
Trend projects are often particularly interesting.
(Image: Rentrop / GitHub)
Once the basic setup is done, the search for the right project follows. Publicly available, open-source projects are displayed on GitHub’s websites, but it’s not always easy to find them. For a first impression, it’s worth taking a look at the trending category. Here you can find projects that are rated as particularly interesting by the GitHub community. The user MunGell has listed some beginner-friendly GitHub projects, he also refers to the search label “first-timers-only”.
Significantly more targeted searches are possible via the Topics category of GitHub, because here projects are listed sorted thematically. Particularly active projects – such as Homebridge-also receive their own category. Another possibility is the search function, which, however, works more badly than right without arguments. Fortunately, there are numerous search arguments on GitHub.
Project found? Then it can already start
If an exciting project is found, you can already start: On the project page there is the button “Fork” at the top right, which also shows how many forks there are already. An indication of how active the project is. By clicking on the button, a fork of the source code repository is created in your own user account.
The fork can be linked, downloaded or-more conveniently – transferred directly to the GitHub desktop app with a further click on the “Code”button. The advantage of this solution is that offline editing is possible, as well as the simple use of the source code with the favorite editor.
GitHub Desktop makes local GitHub usage much easier.
(Image: Rentrop / GitHub)
Changes that are saved in the editor are also automatically stored in the GitHub Desktop and are then traceable. The modified code base can either be used as its own fork or contribute to the main trunk.
Communicating Code changes
If the adjustments, additions or ideas have been incorporated into the source code, the further procedure is no problem: If you want to compile the program locally, you can do this with your favorite compiler. On the other hand, if you want to pass code changes into the root of the project, you can simply create a pull request. This is then displayed in the root and can be adopted by other developers. If the contribution makes sense, it may soon be included in the main project.
Pay attention to the license
Of course, there are some small things to keep in mind: the license should always be kept in mind when a project fork becomes a standalone project or when code fragments of an existing project are to be integrated into a separate project.
Most publicly accessible projects on GitHub are subject to one or the other open source license, but some of them differ significantly. Of course, licensing is also important when creating your own project. To choose the right open source licensing, services such as Choosealicence.com. Here all open source licenses are listed not only with advantages and disadvantages.
By the way: Code projects that do not yet have a license are listed on GitHub under “All rights reserved”, so they may not be taken over by third parties without further ado. There is also the option to use a repository privately: this allows third parties to see it on Github only if the developer shares it.
Good finger exercise or basis for your own projects
Especially younger or orphaned open source projects on GitHub are of course a perfect playground for developers who are looking for a field of activity. The search function allows the targeted search for little forked projects or those that have not shown activity for a long time.
Such projects-if they are subject to an open source license such as GPLv3-can be used at any time as a basis for a new project, provided that you then take over this license yourself, at least for the forked part. But even contributing to one of the larger projects can be a good finger exercise for developers, not to mention the potential improvement of the software itself.
(ID:47383754)