In this tutorial, we will learn how to change a local branch tracking to a different remote in git.
We can change a local branch tracking to a new remote by using the
git push command followed by
-u flag and
git push -u origin dev
dev is my local branch name.
-u flag sets the upstream (tracking) reference to a remote branch.