Steps to remove/changes in last pushed commit
- Get the commit id on which you want to go
git log
- Reset on that commit and this will unstage all the changes
git reset <commit id>
- Now do changes in unstaged files
- To push changes in branch, you have to force push this time
git push origin <branch name> -f
- If you removed the commit, it also removed from server too.
That's how you can do changes even after doing commit
Top comments (0)