remove git commited pushed to master code example
Example 1: cancel a commit not pushed
git reset --soft HEAD~
Example 2: remove commit not pushed
git reset --hard origin/main
git reset --soft HEAD~
git reset --hard origin/main