Differences between local, centralized and distributed version control system

Local version control system

A local version control system is a way of keeping track of the changes you make to your files on your computer. It allows you to save different versions of your files, so you can go back to a previous state if you make a mistake or want to try something different. You can also compare different versions of your files and see what has changed. A local version control system is useful for personal projects or small teams that work on the same computer.

Some drawbacks of the local version control system are:

  • It does not allow collaboration with other developers who work on different computers. You have to manually copy and share your files with them, which can be error-prone and time-consuming.

  • It does not provide a backup of your files in case your computer crashes or gets lost. You have to make sure you have a copy of your files somewhere else, such as an external hard drive or a cloud service.

Centralized version control system

A centralized version control system is a way of keeping track of the changes you make to your files on a remote server. It allows you to upload and download different versions of your files from the server, so you can collaborate with other developers who work on the same project. You can also compare different versions of your files and see what has changed. A centralized version control system is useful for large projects or teams that need a single source of truth for their files.

Some drawbacks of the centralized version control system are:

  • It depends on the availability and reliability of the server. If the server goes down or gets hacked, you may lose access to your files or your files may get corrupted.

  • It requires a constant internet connection to upload and download your files from the server. If you work offline or have a slow connection, you may face delays or errors in your work.

Distributed version control system

A distributed version control system is a way of keeping track of the changes you make to your files on your computer and other computers. It allows you to clone or copy the entire repository of files from another computer, so you can work on your version of the files without depending on a central server. You can also push and pull different versions of your files to and from other computers, so you can collaborate with other developers who work on the same project. You can also compare different versions of your files and see what has changed. A distributed version control system is useful for complex projects or teams that need more flexibility and autonomy for their files. It maintains a local repository and pushes the finalized changes to a central server for backup. A developer can work with local repo without the internet and only requires a connection when pushing or pulling the code from the central repository. Some DVCS: Git, Mercurial