fix(chain): note forward-referenced git commands; fix M6 prerequisites

- M11: keep `git reset --hard HEAD~1` (needed to trigger the protected-branch
  rejection) but flag it as a later-module, history-rewriting command (Module 12).
- Stop presenting rebase/pull --rebase as a casual step: M8 leads with the
  beginner-safe recreate-remote and footnotes pull --rebase as out-of-scope;
  M26 merge-only; M11 mentions rebase-merge only as out-of-scope awareness.
- M6: add Module 3 to prerequisites and back-reference the branch material it
  first taught (branch/switch/merge on docs).

Closes #33
Closes #34
Closes #35

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01TfzV5QvtPDz8LJS3Pu5VLT
This commit is contained in:
2026-06-22 17:06:43 -04:00
parent c34052665f
commit f437d7683b
4 changed files with 33 additions and 15 deletions
@@ -11,6 +11,10 @@
- **Module 2 — Version Control as a Safety Net.** You can `init`, `commit`, read `git diff`/`git
log`/`git status`, and `git restore` an unwanted change. Branches build directly on commits: a
branch is just a label on the commit history you already understand.
- **Module 3 — Version Control for Words.** You first met `git branch`, `git switch -c`, `git merge`,
and `git branch -d` there — on a markdown doc, where a mistake costs nothing and the merge always
fast-forwarded. This module takes those same verbs to *code*, where branches actually diverge and
merges can conflict.
- **Module 4 — Getting the AI Out of the Browser.** The AI now edits your real files directly from
your editor. That's exactly the capability that makes branches matter — you're about to let it edit
files *fast and confidently*, and you want a wall around the blast radius.
@@ -43,6 +47,10 @@ By the end of this module you can:
### What a branch actually is
You already drove this loop once — `git switch -c`, `git merge`, `git branch -d` on a doc in Module 3,
where the merge always fast-forwarded because nothing else had moved. Here the same verbs meet code
that diverges and conflicts, so it's worth pinning down what a branch really is before we lean on it.
Strip the mystique and a branch is **a named, movable pointer to a commit.** That's the whole
definition. Your commit history is a chain of snapshots (Module 2); a branch is a sticky label that
points at one of them and *moves forward* every time you commit on it.
@@ -65,10 +73,11 @@ git branch -d experiment # delete a branch you've already merged
git branch -D experiment # FORCE-delete a branch, merged or not (the "throw it away" button)
```
> **Naming note.** `git switch` (create/move between branches) and `git restore` (the Module 2 undo)
> were split out of the older, overloaded `git checkout` command. You'll still see `git checkout -b
> experiment` everywhere online — it does the same thing as `git switch -c experiment`. Both work;
> this module uses `switch`/`restore` because they say what they mean.
> **Naming note** (you saw the short version in Module 3). `git switch` (create/move between branches)
> and `git restore` (the Module 2 undo) were split out of the older, overloaded `git checkout` command.
> You'll still see `git checkout -b experiment` everywhere online — it does the same thing as
> `git switch -c experiment`. Both work; this module uses `switch`/`restore` because they say what they
> mean.
### The reframe: a branch is a sandbox you can blow away