Let’s Get Certified
Module 02 / 09 · Git and GitHub basics

Trace a release through Git history

Follow a branch pointer, reproduce a released snapshot and explain which changes a teammate can see before and after a push.

A receipt changes after release

Commit R computes a receipt correctly. An unreviewed patch reaches main at S. Three teammates have fetched S. How could they restore the calculation and still show an auditor what happened?

Work through the decision

Create and review a revert of the faulty change. The new tip has a new identity and the original change stays in history. Compare the receipt fixture at R and at the corrected tip, then record the two revisions in the ticket.

Recover an earlier decision

A commit records a snapshot and its parent history. Inspect the change and its message to see why a line moved. A public correction can add a new commit reversing the old one, so colleagues who already use the branch can still follow its history.

Work offline with Git

Git keeps history and creates commits on your machine. GitHub hosts repositories and coordinates work such as reviews, issues and checks. A saved local commit survives a network outage. Pushing later makes it available on a remote branch.

Identify the moving pointer

The repository holds objects. A commit has an identity tied to its contents and metadata. A branch is a movable name for a line of commits. Creating a branch at main initially gives two names to the same commit.

The missing translation

Sam edits a translation on a flight, stages it and commits on copy-edit. On landing, a colleague refreshes main on GitHub and sees the old text. Identify both boundaries between them.

Check your reasoning

The commit exists only in Sam's clone until the branch is pushed. A push of copy-edit still leaves main pointing at its previous snapshot. Open a PR into main so review and merge move the change across the second boundary.

Follow two branch pointers

Git 2.28+ and a POSIX shell. Run this in one terminal. It creates a new temporary repository and sets an identity only inside it. Predict the two file versions before running the final commands.

lab=$(mktemp -d)
git init -q -b main "$lab"
cd "$lab"
git config user.name "Course learner"
git config user.email "learner@example.invalid"
echo first > note.txt
git add note.txt
git commit -qm "Record first version"
git switch -qc edit
echo second > note.txt
git commit -qam "Revise note on edit"
git show main:note.txt
git show edit:note.txt
Expected output and interpretation
first
second

Both names originally identified the same snapshot. The second commit advanced edit alone.

GitHub documentation · GH-900 skills outline

Continue in GitHub Actions. Find the first failing job and reproduce its inputs.

Knowledge check

Trace a release through Git history quiz

Answer 5 questions. Check each answer for an explanation.

Worked example · A review that moved