🚧 Under construction — VoTechWorks is being built. A free tech program — complimentary, as our commitment to get America working.
voTechWorksGrade 13 · a vocational technology learning center, by urbanicity
newSchoolWorks.com › VoTechWorks › Technology & Design › Web & Software Development › Git Version Control for Web & Software Development › Lesson 1
TEC-WEB46-05 · Lesson 1 · 10 clock hours · theory

What Version Control Does and Why It Matters

Objective. Students explain the purpose of version control, describe the difference between centralized and distributed systems, and identify the role of Git in modern software development.

⚠ Pending professional review

This lesson, its worked examples and its practice questions has not yet been verified by an industry-certified professional or by a certification or approval body. It is a study draft and may contain errors. Do not use it as instructions for work on a job site or on live equipment. Always follow your instructor, your supervising professional, and current official references and regulations.

VoTechWorks program approval and accreditation are still in progress. Credentials are issued only by the certifying bodies named in each program, after their own exams.

What Version Control Does and Why It Matters

The Core Problem Version Control Solves

Every software project produces files that change over time. A single developer might edit the same HTML file dozens of times in a week. A team of five developers might edit it dozens of times per day. Without a system to track those changes, serious problems pile up fast: you overwrite a colleague's work, you lose a feature that was deleted two weeks ago, or you cannot tell which version of a file is the one currently running on the production server.

Version control is a system that records changes to files over time so you can recall specific versions later. Think of it as a detailed logbook for your codebase. Every meaningful change is saved with a timestamp, the author's name, and a short description of what changed and why. If something breaks, you can scroll back through that logbook, find the last working state, and restore it.

Centralized vs. Distributed Version Control Systems

Two broad architectures exist, and understanding the difference matters for both your day-to-day work and your credential exams.

Centralized Version Control Systems (CVCS) store the full project history on a single central server. Developers check out individual files from that server, make changes, and check them back in. Subversion (SVN) and CVS are well-known examples. The weakness is obvious: if the central server goes offline or its disk fails, no one can commit work or retrieve history until the server is restored. The entire project history lives in one place.

Distributed Version Control Systems (DVCS) take a different approach. When you clone a repository, you do not just download the latest snapshot of the files — you download the entire history of the project. Every developer's machine holds a full, independent copy of the repository. Git is the most widely used DVCS today. Because every clone is a complete backup, there is no single point of failure. Two developers can work and commit entirely offline, then synchronize their work when they reconnect.

The practical difference: with a CVCS you need network access to commit; with Git you commit locally and push to a shared server when you are ready.

How Git Stores Data: Snapshots, Not Deltas

Many older systems store data as a list of file-based changes — sometimes called delta-based storage. They keep the original file and a chain of differences applied on top of it.

Git does something fundamentally different. Each time you commit, Git takes a snapshot of every tracked file at that moment and stores a reference to that snapshot. If a file has not changed since the last commit, Git stores a link to the previous identical file rather than copying it again. This snapshot model makes operations like branching, merging, and checking out old versions extremely fast, because Git is mostly reading local data rather than recalculating a chain of deltas.

The Three States of a Git File

Understanding these three states is essential — they appear directly in the CompTIA Linux+ exam objectives and in everyday Git work.

1. Modified — You have changed the file in your working directory, but Git has not recorded the change yet. The file differs from what Git last committed.

2. Staged — You have marked a modified file to go into your next commit. The staging area (also called the index) is a preparation zone where you assemble exactly which changes will be recorded in the next snapshot.

3. Committed — The data is safely stored in your local repository database. The change is now part of the project's permanent history.

This leads to three corresponding areas of a Git project: the working tree (your local files on disk), the staging area (your next-commit queue), and the Git repository (the `.git` directory where history lives).

The typical workflow moves in one direction: you edit files in the working tree, you stage the ones you want, and then you commit them to the repository.

Key Git Concepts: commit and HEAD

A commit is a permanent snapshot in the repository. Every commit has a unique identifier (a SHA-1 hash), an author, a timestamp, a message, and a pointer to the previous commit. Commits chain together to form the project history.

HEAD is simply a pointer that tells Git which commit you are currently looking at — usually the latest commit on the branch you are working on. When you make a new commit, HEAD moves forward to point at it.

Why Git Dominates Modern Software Development

Git was created by Linus Torvalds in 2005 to manage the Linux kernel source code. It was designed from the start to be fast, support non-linear development (many branches at once), and handle large projects. Today Git is the de facto standard in the industry. Platforms such as GitHub, GitLab, and Bitbucket are built on top of Git and are central to professional workflows including code review, continuous integration, and open-source collaboration.

Professional Habits and Safety Considerations

In software development, "safety" often means protecting data and systems rather than physical hazards. Two habits that every developer must build from the start:

When working on systems that interact with live servers or databases, treat Git operations on production branches with the same caution you would give any critical system change: confirm what you are doing before you execute it.

Key terms9

Version Control System (VCS)Software that tracks changes to files over time, allowing developers to recall earlier versions, compare changes, and coordinate work across a team.
Centralized VCS (CVCS)A version control architecture in which the complete project history is stored on a single central server; clients check files out from and commit files to that server.
Distributed VCS (DVCS)A version control architecture in which every developer's clone of the repository contains the full project history, eliminating any single point of failure.
Working TreeThe local directory on disk where you view and edit your project files; changes here are not yet tracked by Git until staged and committed.
Staging Area (Index)A preparation zone in Git where you place modified files to be included in the next commit; lets you craft commits with precision.
CommitA permanent snapshot of staged changes saved to the Git repository, identified by a unique SHA-1 hash and accompanied by an author, timestamp, and message.
HEADA special pointer in Git that indicates the commit currently checked out — typically the most recent commit on the active branch.
SnapshotGit's method of storing data: each commit records the state of every tracked file at that moment, rather than storing only the differences from the previous version.
RepositoryThe `.git` directory that stores the complete history of a project — all commits, branches, tags, and configuration — on the local machine or a remote server.
In class: Read and annotate the first two chapters of the Pro Git book (Chacon & Straub, freely available at git-scm.com), then answer a set of comprehension questions covering distributed vs. centralized VCS, snapshots vs. deltas, and the three states of a Git file. · Participate in a class discussion comparing a scenario of sharing code via email attachments versus using Git, identifying specific problems Git solves such as version history, rollback, and parallel work. · Complete a matching exercise that pairs Git terminology (working tree, staging area, repository, commit, HEAD) with plain-language definitions, then self-grade using the answer key.
Materials: Pro Git book (git-scm.com/book), whiteboard, printed terminology matching worksheet, internet-connected workstations
Check: Score of 80% or higher on a 20-question written quiz covering VCS concepts, Git's distributed model, and the three-state file lifecycle.

Practice check8

Answer each question, then check it. Nothing is recorded; this is your own practice.

CompTIA ITF+ — IT Concepts and Terminology
1. What is the primary purpose of a version control system?
CompTIA Linux+ — System Management
2. A team uses a centralized version control system. The central server suffers a complete disk failure with no backup. What is the most serious consequence?
CompTIA Linux+ — System Management
3. Which statement correctly describes how Git stores project data?
CompTIA Linux+ — System Management
4. A developer edits `index.html` but has not run `git add` yet. What state is the file in?
CompTIA Linux+ — System Management
5. After running `git add report.py`, the file `report.py` moves to which state?
CompTIA ITF+ — IT Concepts and Terminology
6. In a distributed version control system, what does every developer's clone of a repository contain?
CompTIA Linux+ — System Management
7. What does the Git pointer called HEAD typically indicate?
CompTIA ITF+ — IT Concepts and Terminology
8. A development team used to share code by emailing zip files. Which specific advantage does Git provide that directly solves the problem of two developers accidentally overwriting each other's work?
Record this lesson on my transcript. Sign in with your key and enrollment email to record lessons (enroll free if you have no key). This page stays open to read and practise.