-
We want to make sure to add a new remote as normal:
git remote add <remote name> <url for git repo> -
Now we can setup multiple
originpush urls:
git remote set-url --add --push origin <git url one>git remote set-url --add --push origin <git url two>
- Last step, you will need to set the upstream branch again
git push -u origin master
Done! Now whenever you run git push it will simultaneously push to both remote repos.
You can type git config -l (list) or git config -e (edit) to confirm. You should see two remote.origin.pushurls in there