If you have committed junk but not pushed
# deletes the commit but it will leave all your changed files "Changes to be committed"
git reset --soft HEAD~1
# deletes the commit and gets rid of any changes to tracked files
git reset --hard HEAD~1
If you already pushed and someone pulled
git revert HEAD