How to push branches to a git remote using Terminal


A step by step guide on pushing all your branches to new git remote using Terminal.
Step One: Set the current directory

Open Terminal, and set the current directory to that of your project using a command similar to the one below.
cd path/to/your/project
Step Two: Get all branches

Run the following line in Terminal to fetch and pull all the branches
git fetch --all; git pull --all
Step Three: Push all the branches to remote

Push all the branches to your new remote by running the line below in Terminal.
git push -u [REMOTE_NAME] --all; git push -u [REMOTE_NAME] --tags
Please ensure that you replace REMOTE_NAME with the name of your Git remote.
Any Questions?
We are actively looking for feedback on how to improve this resource. Please send us a note to inquiries@delasign.com with any thoughts or feedback you may have.