Forces an update of the remote branch after rewriting the history locally.
git push -f
to force update the remote branch, overwriting it using the local branch's changes.git push -f
git checkout patch-1
git pull
git rebase master
# Local `patch-1` branch has been rebased onto `master`, thus diverging
# from the remote `patch-1` branch
git push -f # Force update the remote `patch-1` branch
Git, Branch
Renames a branch both locally and on the remote.
Git, Branch
Moves local commits from the master
branch to a new branch.
Git, Branch
Creates and switches to a new branch, optionally setting up a remote tracking branch.