DEV Community

Héctor de Isidro
Héctor de Isidro

Posted on • Edited on

Moving from GitHub to Bitbucket

W̶h̶y̶ ̶a̶n̶d̶ how

Disclaimer: This post is not related in any way to Microsoft’s recent acquisition of GitHub (I don’t really have a very strong opinion about it; although I hope that won’t affect us at all).

Next month, my GitHub annual subscription will end and I don’t want to renew it in order to reduce the high number of online services I currently pay for.
tl;dr: I’ll continue to use GitHub but not for private repositories.

There are many alternatives out there, but I’ve decided to migrate my private repositories to Bitbucket¹ (mainly because I’m used to using it at work²). The biggest obstacle is that they don’t provide any tool to import all the repos at once (we have to do the chore one by one…) so I’ve created a script³ to fill that gap. You’re welcome, Bitbucket :wink:

Moving checklist

As you can see, we won’t expose any of our account passwords, so we can delete those temporary credentials afterwards.

Moving day

This article was originally published on Medium


[1] Even though some people think it’s the ugliest one :wink:
[2] Also, I tried Gitlab long time ago and IMO their website was running slow and sluggish. Perhaps they have solved this by now, IDK :shrug:
[3] It has been tested under Linux/MacOS. What about Windows users? Well, can you tell me why you’re still using Windows? :trollface:


External links 👀

Top comments (5)

Collapse
 
rhymes profile image
rhymes • Edited

Why do you need a script to move?

Isn't it just easier to add bitbucket's repository as a remote and push there?

You can also use Bitbucket's import functionality: bitbucket.org/repo/import

:-)

Collapse
 
hector6872 profile image
Héctor de Isidro

I had more than 65 repos on GitHub so doing that manually it was not an option :)

Collapse
 
rhymes profile image
rhymes

OMG that's a lot! ahhahaha :-D

Collapse
 
qm3ster profile image
Mihail Malo

GitLab's import is oh-so-sweet.
It takes wikis, comments, and everything, not just the git.

Collapse
 
hector6872 profile image
Héctor de Isidro

Totally agree.