I\'m not really familiar with how git works. I pushed a commit by mistake and want to revert it. I did a
git reset --hard HEAD~1
Bewar
Or you can try using git revert http://www.kernel.org/pub/software/scm/git/docs/git-revert.html. I think something like git revert HEAD~1 -m 1 will revert your last commit (if it's still the last commit).
git revert HEAD~1 -m 1