Version Control System
A version control system tracks changes to a file (or files) over time so that you can see how things have changed and, if needed, revert to a previous version. Each change is maintained as a version. Users can track specific versions later. Version control systems are also called as revision control systems. The unique features of version control system/ revision control system are as follows:
- Up to date history is available for the document and file types.
- Allows developers to work simultaneously.
- Does not allow overwriting each other’s changes.
- The repositories can be cloned as per the need and availability. This is extremely helpful in case of failure and accidental deletions.
The various types of the version control systems are :
- Centralized Version Control System
- Distributed Version Control System
Centralized Version Control Systems :
In this approach, all the changes in the files are tracked under the centralized server. The centralized server includes all the information of versioned files, and list of clients that check out files from that central place. But, its’s the major drawback is single point of failure, i.e., failure of the central server. Unfortunately, if the central server goes down for an hour, then during that hour, no one can collaborate at all. And even in a worst case, if the disk of the central server gets corrupted and proper backup has not been taken, then you will lose the entire history of the project.
Example : Tortoise SVN
Distributed Version Control System :
Distributed version control systems come into picture to overcome the drawback of centralized version control system. The clients completely clone the repository including its full history. If any server dies, any of the client repositories can be copied on to the server which help restore the server. Every clone is considered as a full backup of all the data.
Example : Git
Git :
Git has a remote repository which is stored in a server and a local repository which is stored in the computer of each developer. This means that the code is not just stored in a central server, but the full copy of the code is present in all the developers’ computers. Git is a Distributed Version Control System since the code is present in every developer’s computer.
Advantages of Git
- Free and open source
- Fast and small
- Implicit backup
- Easier branching
- Security
GitHub :
GitHub is a free, cloud-hosted platform for code. It works with Git on your and your colleagues’ computers, serving as the origin. You and your collaborators upload their code to GitHub periodically, and GitHub provides tooling to help manage changes to the code over time.