Discussion on: Oops, I just pushed a git commit to the wrong branch. What now?

lietux profile image
Janne "Lietu" Enberg

Well your #1 priority should be to fix what you broke. Since revert does not remove the commit, you don't need to hurry with "saving it" or anything - first revert and push to fix what you broke, then you can go about cherry-picking it to where you needed the code in.