git undo last commit

Shell
$ git reset --soft HEAD~1
git reset --soft HEAD~1# KEEP CHANGES
git reset --soft HEAD~1

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

Also in Shell: