Faraway Technologies

thoughts & experiments.

Migrating bitbucket.org issues between the repos

16 December 2012 • en, bitbucket, python

Bitbucket is definetly a nice code hosting system, which offers you private repositories for free. This feature favourably distinguishes it from GitHub, for example.

Until October 2011, bitbucket only supported Mercurial as a DVCS system to store your repositories, but then Git support was introduced as well. Unfortunately, it was not possible to convert your project to Git by simply clicking on a button. You have to move everything to a new repository yourself using hg-fast-export or something.

But let’s say you want to also move all your issues to a new repo. It is not possible either. There still exists an open ticket created 3 years ago regarding this problem: https://bitbucket.org/site/master/issue/1642/allow-moving-tickets-over-to-another. So, since I did not found any reasonable solution (except this post on Spanish from the comments of the ticket), I deciced to create this simple gist to solve the problem: https://gist.github.com/4297504.

Basically, it uses the bitbucket API through the Basic Auth to access the data and clones the following fields to the target repository: title, content (description), priority, status, kind (bug/enhancement/etc.)

Happy migrating!



comments powered by Disqus