DEV Community

Discussion on: The Magic of Empty Git Commit

Collapse
 
lewiscowles1986 profile image
Lewis Cowles

Did you know you can choose to commit a file with the exact same contents over multiple commits, without worrying about needing to rebase or address conflicts?

I only found out while using GitHub API via JS. I even checked their UI to see if behind the scenes it was an empty commit. It was not.

Lots of odd things you can do with git. Likely there are very good reasons you should not though 😉

Collapse
 
pradumnasaraf profile image
Pradumna Saraf

Check out projects like Kubernetes, Flutter, etc., and you will understand why you need this in PRs. 😉

Some comments have been hidden by the post's author - find out more