I have a repo with two remotes (one for the company I work for, one for our client). One remote is called
github and the other is called
origin. As you can see, each one should have 3 identical branches:
To make it easier to know which local branch I’m on, I’ve renamed the locals by doing
right-click > rename [branchName]...
That way I know what I’m tracking:
REMOTE LOCAL origin/develop => originDevelop github/develop => develop
The problem is that when I push a commit from local
originDevelop to remote
origin/develop, it creates a new remote branch named
origin/originDevelop. I never asked to create a new remote, it just does it automatically when I push!
Is this a bug? How can I make local branch
originDevelop track remote
origin/develop without having it automatically create a new remote branch? Why does renaming a local branch automatically create a remote?