git reset is a Git command used to undo changes in your working directory and staging area. It can be used to move the current HEAD to a specified state, and it has three main modes:
- Soft Reset: Moves the HEAD to a previous commit but leaves the changes in the staging area.
- Mixed Reset: Moves the HEAD to a previous commit and unstages the changes but keeps them in the working directory.
- Hard Reset: Moves the HEAD to a previous commit and discards all changes in the working directory and staging area.