I have multiple repositories in BitBucket. What is the most appropriate way to migrate from BitBucket to GitLab?
For an example, I maintain a repo on my system named "SSSP". What should be my steps to have a clean migration of that repository from BitBucket to GitLab?
From the repository you want to transfer, click Repository settings in the left menu. On the Repository details page, click Manage repository located at the top-right corner of the screen. Click Transfer repository. Enter the Workspace ID of the workspace in which you want to transfer the repository.
No Two Factor Auth (This is no longer the case, Bitbucket supports Two Factor Auth) GitHub UI is more intuitive to navigate and work with. GitHub issues are much more powerful (labels, milestones) GitHub PR's are much nicer (Split diffs, less cluttered UI, Status API is cleaner)
It is better to use an intermediate local bare repo in order to duplicate one remote repo and push it to a new remote one.
Assuming you have an empty gitlab repo ready:
git clone --bare [email protected]:old/old_repo.git
cd old_repo
git remote add new-origin [email protected]:new/new_repo.git
git push --mirror new-origin
cd ..
git clone [email protected]:new/new_repo.git repo
cd repo
# start working
Note that this won't include the wiki (which you need to clone as well if you have some content there), or the issues.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With