The board where “rollback = git revert” and “audit = git log” are one-liners. This lesson builds the two commands those lines lean on: reading history back, and putting a folder back the way a commit had it.
Before you start.Git 03: Commits, Refs and HEAD made the commit: a top tree, a parent hash, an author and a message, with a branch file holding the newest one and HEAD naming the branch. Each commit points at its parent, so the history is a chain you can follow backwards. A root commit is the first one, the one with no parent line. This lesson covers two stages, because each is short: 04-log walks the chain, and 05-checkout rebuilds a folder from it.
Lesson 36 of 117 in From Scratch
The rest of this lesson is part of a plan.
A plan opens every lesson, board, video, lab and paper on chalk. Yearly is $39/year.