brewly — Ch.1 · Your first commit
Exercise 5 of 11
Before you start
Stage, then commit
Saving a change takes two steps. First you stage it: you put it in the staging area. Then you commit: git saves everything staged as one snapshot.
Every commit needs a message saying what you did. Put it in quotes after -m.
- git status
- which files changed, and what is staged?
- git add <file>
- stage the changes of one file
- git diff --staged
- review exactly what the commit will contain
- git commit -m "What you did"
- save the staged changes
You can reopen this any time with “Lesson”.
# BrewlyOrder coffee ahead.## Team- Maya (lead)- Alex (frontend)- Sam (new!)
Graph
- 1354d06 Add menu pageHEAD → mainorigin/main
- 619eb3b Style the order button
- 5fc44ac Initial commit