I\'m trying to delete the last 2 commits from one of my GitHub repositories. I\'ve tried as suggested here : git push -f origin HEAD^^:master. It seems that it
It removes the last n commits from local repo, as HEAD^ removes only one. If you need to remove these changes from remote, you might need to force push as you will be behind remote.