Skip to main content

Command Palette

Search for a command to run...

Why Version Control Exists: The Pendrive Problem

Updated
•3 min read•View as Markdown

Why Version Control Exists

Version control system (VCS) is used to track changes in your code and code files systematically. It helps in making different versions of a program. It can also revert to previous versions of a software, if there was a flaw in the current or some other version of the software.

The Pendrive Analogy in Software Development

Before version control systems, developers used USB drives or pendrives to collaborate. They shared one common USB drive with all the project files. Only one coder could code at a time.

If another coder changed something in his copy of the code, everything went out of sync. It could make a total mess.

They made folders named "final", "final_v2", "latest final", etc to make different versions of a software. This included manual folder making and extra work for just making different versions of a software.

These problems were faced by millions of coders. They couldn't collaborate and code at the same time. They couldn't make different versions of a software. Instead they had to make different folders for different versions.

Problems Faced Before Version Control Systems

These were the problems faced before version control systems:

  1. Accidental Overwrites: When multiple people edited the same file, one developer could easily overwrite another's changes without noticing.

  2. Version Chaos: Without VCS, developers couldn't make different versions of a software without making folders like "final_v2", "latest_final", etc.

  3. No Change History: It was somewhat impossible to track who made specific change, what was the time when they were made, or why, making it difficult to identify bugs.

  4. Difficulty Undoing Changes: When there was no version control systems reverting to previous version of a software was a nightmare.

  5. Collaboration Inefficiency: When developers wanted to collaborate they had to make some different folders and sometimes share a USB drives and imagine the USB drives as the single source of truth. If any other coder (which doesn't have the USB drives) made changes in his copy of the project everyone goes out of sync and it can make a huge mess.

  6. High Risk of Data Loss: If a single computer or shared drive crashes, the entire project and its history could be lost forever. If one of the shared drives like USB drives, etc. crashes it can cause a whole data loss.

  7. Fear of Experimentation: Without git, which includes branching, early developers had the fear of experimentation because a bug can cause whole project to crash.

  8. Complicated Deployment: Without a clear "main" branch, identifying which specific set of files was ready for production and can be launched without any manual work which was difficult.

2 views