L
L
Leestex2013-03-25 04:31:31
git
Leestex, 2013-03-25 04:31:31

Transferring a repository from Bitbucket to Github

There was a need to migrate an existing repository from Bitbucket to Github.
The reason is that the second one is better and cheaper as a paid resource (I initially chose bitbucket because of the ability to create free private repositories).

So, is there a simple or complex way to transfer all this goodness while preserving the commit history?

Thanks in advance to everyone for your help.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
Y
Yuri Shikanov, 2013-03-25
@Leestex

Exist. It's very simple.
- Clone the repository from bitbucket.
- Create a new repository on github
- Add the address of the new repository: git remote add github <new_repository_address>
- Push to the new repository: git push github master

Y
yulyugin, 2013-08-15
@yulyugin

git clone --bare --mirror oldgitrepourl.git repo.git
cd repo.git
git push --mirror newgitrepourl

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question