git reset HEAD
Should do it. If you don't have any uncommitted changes that you care about, then
git reset --hard HEAD
should forcibly reset everything to your last commit. If you do have uncommitted changes, but the first command doesn't work, then save your uncommitted changes with git stash
:
git stash
git reset --hard HEAD
git stash pop
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…