DEV Community

Discussion on: Git: Cheat Sheet (advanced)

Collapse
 
dhirajpatra profile image
Dhiraj Patra

Nice post Maxence.

If you need to overwrite the master from the dev branch any time:

git branch -f master dev_branch [will rewrite local master branch.]

git push remote +dev_branch:master [will rewrite remote branch.]