Git · Junior · Question 52 of 75
What is the danger of git reset --hard?
- ✓Correct answer: Uncommitted changes in the working tree are lost
- 2The remote repository is reset as well
- 3All branches except the current one are deleted
Explanation
--hard overwrites the index and working tree. Committed work can usually be recovered through the reflog, but uncommitted edits are gone.