Plenty of developers get by with three commands: add, commit, push. That works until the day something goes wrong — a bad merge, a change committed to the wrong branch, a file you did not mean to include. In those moments the difference between panic and a calm two-minute fix is knowing a slightly wider slice of Git.
None of these require deep internals. They are everyday tools that turn Git from a thing you fight into a safety net you trust.
Seeing where you are
Before changing anything, look. Status shows what is staged, modified and untracked. Diff shows the exact lines you are about to commit, which catches stray debug code and accidental edits before they enter history. Log, especially in its compact one-line form, shows the shape of recent history so you know which commit is which.
Understanding the current state is half of using Git well. Most destructive mistakes happen because someone acted on an assumption about what was staged or which branch they were on. A five-second look replaces the assumption with a fact.
Undoing safely
To discard uncommitted changes to a file, restore it. To unstage something you added by mistake without losing the work, restore it from the staging area. To keep changes but move them off the current branch, stash them, switch, and pop them back — invaluable when you started work on the wrong branch.
For commits, reset moves the branch pointer: a soft reset keeps your changes staged, a mixed reset keeps them in your working files, and a hard reset throws them away — powerful and the one to respect. When you have already shared a commit and want to undo it without rewriting shared history, revert creates a new commit that cancels it out, which is the polite choice on shared branches.
The recovery net most people miss
The command that saves careers is reflog. Git records almost every move of your branch pointers — commits, resets, checkouts — for weeks, even ones that seem lost. If a reset or rebase appears to have destroyed work, the reflog usually still lists the commit you were on, and you can return to it. Very little is ever truly gone in Git while the repository exists.
Knowing that safety net is there changes how you work: you experiment more freely, because you know how to get back. That confidence, more than any single command, is what separates people who tolerate Git from people who use it well.