git
Git, from zero to senior
Start having never run `git init`. Finish able to branch, rebase, recover lost work, rewrite history — including changing a commit's author — and run the branching workflow a real team ships on.
Start track → 01
Version control & the git model
Git records your project as a series of full snapshots, not a pile of diffs. Understand the three places a file can live — working tree, staging area, repository — and you understand most of git. 02
Recording changes
The core loop: edit, stage, commit. Read what changed with status and diff, keep junk out with .gitignore, and write commits a teammate — or future you — can actually use. 03
Branches & merging
A branch is just a movable pointer to a commit — cheap to make, cheap to throw away. Create them, switch between them, merge them back, and resolve the conflicts that result. 04
Undo & rewrite history
Mistakes are recoverable. Discard changes with restore, move HEAD with reset, undo safely with revert, recover deleted commits with reflog, and reshape history with interactive rebase — including changing a commit's author and date. 05
Remotes & collaboration
A remote is another copy of your repo — usually on GitHub. Push your commits to it, fetch others', and understand the remote-tracking branches that mirror its state, so a team can work on one project without overwriting each other. 06
Team workflows
A branching workflow is a team's contract for how code moves from idea to production. Compare the three that real companies run — git-flow, GitHub flow, trunk-based — and learn to pick the one that fits a team's size and release cadence. 07
Daily power tools
The commands seniors reach for without thinking: stash work-in-progress, cherry-pick a single commit, tag a release, run two branches at once with worktrees, and bend git to your hands with aliases and config. 08
Under the hood
Git is a content-addressed object store with pointers on top. See the four object types, how refs and HEAD index them, how merge and rebase actually replay commits, and how hooks let you run code on git events. 09
Scaling & rescue
Big repos and bad days. Clone huge histories cheaply, vendor code with submodules, scrub secrets from all history with filter-repo, sign your commits for trust, and bring a repo back from the dead. 10