What is Version Control?

Version control systems (VCS), also known as source code management (SCM) systems, allow you to keep track of every change to your codebase. By keeping your files in a version control system, you can see every edit, addition or deletion, when it was made and by whom.

You can also revert to an earlier state and compare changes to files over time. Version control is a must-have tool for modern software development. Not only does it give everyone visibility of changes, but it allows multiple people to work on the same files and merge their updates, making it easier to manage versions and releases.

Version control systems come in two main flavors: distributed and centralized. In a centralized system, all files are stored on a central server and individual users “check out” a local copy of the files, which they then synchronize with the central source of truth.

However, the main disadvantage of this approach is that the central server is a single point of failure. By contrast, there are multiple copies of the files in a distributed version control system and, therefore, multiple sources of truth.

Whichever system you use, the basic steps will involve updating your local copy of the source files, working on changes locally, and then sharing those changes with others in the form of a commit.

Putting all the files to build your application into a single version control repository that everyone can access is the first step towards implementing continuous integration and building a CI/CD pipeline.

Doing so enables everyone to share their changes regularly, thereby triggering the automated build and test process to provide rapid feedback on changes.

When issues arise – either in testing or production – you can identify the commits that introduced the problem and use the revision history to understand exactly what changed.