I just commit and push in the same line, all the time. Whenever I have to undo a change, I go to GitHub/Gitlab browse for the previous version and paste from there.
I definitely know is not the intended way to do this, but it works for me and has saved my ass several times.
It's classic rightwinger stuff anyway: nothing should be regulated, everything just works, oh my god my car broke my family's dead my ass is on fire...
American food makes British food look yummy.