When you do the initial push add the -u parameter:
git push -u origin my_branch:remote_branch
Subsequent pushes will go where you want.
EDIT:
As per the comment, that only sets up pull.
git branch --set-upstream
should do it.
More Related Contents:
- How do I push a new local branch to a remote Git repository and track it too?
- Warning: push.default is unset; its implicit value is changing in Git 2.0
- Remote origin already exists on ‘git push’ to a new repository
- What are the differences between local branch, local tracking branch, remote branch and remote tracking branch?
- Git – What is the difference between push.default “matching” and “simple”
- What is the difference between git push origin and git push origin master
- What does ‘–set-upstream’ do?
- Changing the Git remote ‘push to’ default
- How can I find the location of origin/master in git, and how do I change it?
- When doing a ‘git push’, what does ‘–set-upstream’ do?
- How do I force "git pull" to overwrite local files?
- Is there a way to cache https credentials for pushing commits?
- How can I see the changes in a Git commit?
- How do I properly force a Git push?
- Git cherry pick and datamodel integrity
- Updates were rejected because the remote contains work that you do not have locally
- Should “node_modules” folder be included in the git repository
- Remove file from git repository (history)
- Trying To Understand/Determine A Basic Git Workflow
- Is it possible to alias a branch in Git?
- Git submodule to track remote branch
- Visual Studio Git Source Control without Git for Windows or Github extension
- Heroku: How to push different local Git branches to Heroku/master
- git-svn: how do I create a new svn branch via git?
- Git merging within a line
- How do I change the URI (URL) for a remote Git repository?
- Does git ignore empty folders?
- How do I remove a single file from the staging area (undo git add)?
- How to convert a Git repo to a submodule, which is nested in another (parent) Git repo?
- How to pull remote branch from somebody else’s repo