undo commit

Shell
$ git reset --hard 0ad5a7a6
// use --soft to reset as uncommitted change,
// or --hard to completely remove# KEEP CHANGES
git reset --soft HEAD~1

# REMOVE CHANGES
git reset --hard HEAD~1$ git reset --hard HEAD~1
$ git reset --soft HEAD~1
$ git reset --soft HEAD~1git reset --soft HEAD~1
Source

Also in Shell: