DEV Community

loading...

Discussion on: Want to remove/delete your last commit? Here is how.

Collapse
danielpdev profile image
danielpdev

Great post.
You could also use git reset --hard HEAD~1 to remove the last commit, be aware that it will also remove all of your uncommitted changes.