Version Control System

When people screw up their life, they call God for help.
When developer screws things up, They call VCS for help.

 

What is Version Control System(VCS)?
Version Control is a system/tool that tracks changes to a file or set of files over time.

Why should one use VCS?

  • It allows one to track back to the previous version if something went wrong.
  • One can compare earlier versions to fix the mistakes.
  • One revert a file or entire project to previous version.

Where can one use VCS?
One can use it to any system that changes over time.

Example:-

  • Software Development
  • Website Development
  • Graphic Development :- One can stores various version of design.

 

Few Solution to maintain different version of codes

Method-1:- I am using this method, before Git came to my life.
Simply copy files into another directory. This approach is very common, easy to use.

Drawback
Error-Prone, One can easily forget which directory has a new version of the code.
Comparison between different directories is not an easy task for bigger projects.

Method-2:-Local Version Control Systems
To deal with the issues in method-1, people come up with local VCSs that keep all change to file in the database.
Only one copy of the file is maintained, and all changes are placed in the database.

Drawback
In the case of database failure, you will lose all your records.
Difficult for multiple people to work on the same project, as change records are local to one’s system.

Method 3:- Centralized Version Control Systems
To encounter the problems of method-2. CVCSs is developed where a single server will record all version information and can be shared among various people.

Drawback
In the case of database failure of the single server, you will lose all your records.
Even if database if offline for the certain duration, no one can work.

Example: -CVS, Subversion, Perforce etc.

Method:- 4 Distributed Version Control Systems
Instead of one database, now we have multiple.

Example:- Git, Mercurial, Bazaar, Darcs etc.

 

Do Check this

https://git-scm.com/book/en/v2/Getting-Started-About-Version-Control

 

Posted in Git.