git reset --hard <commit>

Term side of the Card
Topic: Git Commands - Undo Changes
Unit title: git reset --hard <commit>
Categories: Command
Explanation side of the Card

Explanation: The command that moves the HEAD pointer to a specific commit and removes all staged and working directory changes. Hard reset is irreversible and erases modifications.

Edit on GitHubContributions in our content repository are 🤗 welcome from everyone.Link leads to the Contributions guidelines on GitHubLink leads to the content repository on GitHub