Git is one of the most popular software source code control version system (CVS).
This post explains the main aspects of Git.
Explaining what is Git
Git is free and open source (FOSS) control version system (CVS). As its code is publicly available under a copyleft GPL-2.0-only license, it can be implemented by anyone.
It was developed initially by Finnish developer Linus Torvalds, the same that created the Linux kernel.
Git can be downloaded and installed on a personal computer or server.
Many popular CVS cloud services, like GitHub, are based on Git. The concepts of Git and these cloud services are very similar, so if you want to use any of these services it is important that you are familiar with Git.
The source code of a software project is stored on a code repository, also known as repository or repo.
A branch is a version of a project. There is usually a main branch on all projects. When a developer wants to make changes on a project, it usually uses its own branch.
A commit is a snapshot of the project at a particular point. One of the interesting functionalities of code repositories is version history, and storing different commits enables it by keeping different snapshots of the same project.
A pull request is a proposal to merge the changes from or a branch into another branch or from a a clone repository to the original repository.
Pull requests can be accepted or rejected.
Then, as a last step, changes are merged.
gitignore is a file that specifies all files that should be ignored by Git. It is used to ignore, for example, system folders or files that are used locally by the OS of a personal computer and should not be pushed to a common repository.
You can find more information about gitignore on this external link.
You might also be interested in…
- Eric Matthes; “Python Crash Course, Third Editon“, appendix D “Using Git for Version Control”, No Starch Press, 2023