Due to some bad cherry-picking, my local Git repository is currently five commits ahead of the origin, and not in a good state. I want to get rid of all these commits and st
If you just want to throw away local commits and keep the modifications done in files then do git reset @~ Other answers addressed the hard reset