Import missing pull request history

Hello,

I’ve been importing some private repos from bitbucket into GitHub. And everything appears to be working except for pull requests.

Is it possible to import a private repository and keep the merged/closed pull requests? I’d like to keep them for reference.

Thanks!

GitHub doesn’t offer a way to import pull requests currently. It might be something we offer in the future, but it probably won’t happen in the near future.

An alternative approach that you could try:

For each pull request on BitBucket, you could use this endpoint to create an issue:

For each of comment in the pull request, you could use this endpoint to create a comment in the issue you just created:

This approach would “preserve” the textual history, specifically the conversation around the BitBucket pull request. It’s not a 1-1 solution, but the goal of preservation is met.