Reputation: 2092
Up till now, I worked on a local repository ( locally initialized, not cloned ). Because I am working on more than one workstation, I decided to "go online" and want to push my repo to server. Also, I want to push all branches.
So question is: Is there any way of pushing whole locally initialized repo ?
Upvotes: 4
Views: 8806
Reputation: 496782
To make things easier, start by creating a remote if you haven't already:
git remote add origin <server repo url>
Now you can do this:
git push --all
to push all branches to origin, the default remote. (If you name it something else, you'd have to specify it as an argument.)
Upvotes: 6