How to make `git push -f` "safe" -


is there way use git push -f, origin/master hasn't changed since last pull?

i want reorganize history, not overwrite file contents.

there option called --force-with-lease git push. doing

git push --force-with-lease 

will desire , force-update remote branch if still on same version remote tracking branch (i.e. origin/branch).

you can specify revision explicitely if want check version:

git push --force-with-lease=branch:somecommithash 

Comments

Popular posts from this blog

rdbms - what exactly the undo information lives in oracle? -

bash - How do you programmatically add a bats test? -

javascript - RequestAnimationFrame not working when exiting fullscreen switching space on Safari -