Diff
ELI5 — The Vibe Check
A diff shows you exactly what changed between two versions of your code. Lines that were added show up in green with a +, and lines that were removed show up in red with a -. It's like a 'spot the difference' game for code.
Real Talk
A diff (short for difference) is a comparison between two states of a file or set of files. Git diff shows line-by-line changes in unified diff format. It's used for code review, debugging, and understanding changes.
Show Me The Code
git diff # unstaged changes
git diff --staged # staged changes
git diff main..feature # between branches
When You'll Hear This
"Check the diff before committing." / "The diff is huge — can you break this into smaller PRs?"
Related Terms
Commit
A commit is like pressing the save button in a video game.
Pull Request (PR)
A pull request is like raising your hand in class and saying 'Hey, I made some changes — can someone check my work before we make it official?
Staging Area
The staging area is like a shopping cart. Before you 'buy' (commit) your changes, you put them in the cart first with `git add`.