Migrating Bitbucket Repos To Github
With many reasons, I decided to consolidate all my repos from Bitbucket to Github. Of course, this comes with costs which I will talk about later.
What I anticipate is a copy of all my repos in Github, and I will then no longer be using Bitbucket as
To achieve it, I have to:
- clone all my repos from Bitbucket
- create repos of same names in Github
- update the
originof existing repos to the Github URLs.
These seem tedious if you do them manually. Luckily, someone has prepared a script for this purpose.
bitbucket-to-github and added some extra bit to make it more relevant to my situation. In my version, I made these changes:
- operations of same kind are run concurrently
- repositories are cloned using SSH instead of HTTPS
The script is not a sophisticated piece, it is meant to “Get the job done!”. So, while the script is executing, monitor the console output all the time. Any error will not likely to halt the entire script but the message will be printed to the console.
In my case, one of my repos are not able to push to Github as I have blobs larger than 100mb. I didn’t spend time to work around it as the files are just some pickled trained NN model from my uni class long time ago.