Version Control

Azay Karimli
4 min readApr 25, 2021
Photo by Christina @ on Unsplash

What is version control?

First of all, this is not one of those boring articles like what are the benefits of version control systems, why you should use them, and so on. The point is that it is essential, and you should use it. I do not understand these kinds of things easily, I need a simple explanation from the ground up. So, before I get into using Git, GitHub, or any other version control systems, I need to understand what the heck version control is.

Along the way, I found out that…

Gentle INTRO.

Version control is a class of systems that records changes to a file or set of files over time, along with information such as who, when, and what, so that you can recall specific versions later. It is an important component of software configuration management. It does not matter if you are working alone or part of a large group project it is very useful in both cases. Multiple people are working on the same project simultaneously independently. This means that each person edits her or his copy and decided for themselves when to share it with others so that temporary or partial edits do not interfere with others' work.

How does it work?

There are 2 main parts to the whole system: repository and working copy. The repository (GitHub is the perfect example for repo) is the database of changes and the working copy is where you work. When making arbitrary edits to your copy (sometimes referred to as check out) you commit changes to the repository.

All edits, and/or historical versions (snapshots) of your project are kept in the repository. The repository may contain edits that have not yet been applied to your working copy. You can update your working copy to include any new edits or versions that have been added to the repository since the last update. See diagram 1.

In the simplest case, the database contains a linear history: each change is made after the previous one. Another possibility is that different users have made edits simultaneously (this is sometimes called “branching”). In this case, the version history splits and then merges again. See diagram 2.

VCS allows users to work on their code and separate their tasks through branches. Changes are never made directly to the main code but…