What is version control?

Let's imagine...

Version control to the rescue!

Taking a closer look

Let's visit Wikipedia.

Every Wikipedia page, including the main page, has a special view. You can find it in the top right-hand corner of the screen: it says "View History". Pick a page -- any page -- and find the "View History" tab. Then click it.

This page shows you every change ever made to the page. These changes are saved as "diffs". Diffs are a list of the changes or differences between two versions of a file. If you want to learn more about diffs, try the OpenHatch diff and patch training mission.

Wikipedia displays diffs in its own particular way. Select two revisions and click "compare selected revisions" to view it.

(Click on the image to go to the diff itself.)

The diff includes information about:

  • what got added (in blue) and what got deleted (in yellow)
  • the lines of the documents the deletions were on
  • who made the change
  • when they made it
  • why they made it - the "commit message"
  • how to view the previous version and the new version
    (click on the bolded "revision as of...")

That's Wikipedia. It runs on a piece of software called Mediawiki. That's one version control system. What others are there?

And what's the difference between a version control system and a repository and a host, anyway?

Version control works on more than just code! You can use it to host poetry, resumes, laws and more.