Remove commits on GitHub
At first fix commit history.
Example:
git reset --hard HEAD^
Force push the branch.
git push origin master --force
If you push the branch without '--force' argument, then the operation will be rejected.
NOTE: You must not change the history of shared gits.
Written by sfuku7
Related protips
Have a fresh tip? Share with Coderwall community!
Post
Post a tip
Best
#Git
Authors
Sponsored by #native_company# — Learn More
#native_title#
#native_desc#