Question

I have some project on some repository. This repository is using Mercurial version of TortoiseHG. Now I want take this repo and put to the other repository using the same tool TortoiseHG but other repository for example Bitbucket or GitHub. How to move every commit and all branch and every information send before to new repository? Thanks for the help.

Was it helpful?

Solution

TortoiseHg is only a Mercurial client, not a Git client. So your Mercurial repository will stay as a Mercurial repository after you move it. GitHub does not support Mercurial, but Bitbucket does.

So you should go create a new Mercurial repository on Bitbucket. They will show you a guide when you create a new empty repository. You basically have to go do the .hg/hgrc file of the repository and change the default path so it looks like this:

[paths]
default = https://bitbucket.org/your-username/your-repo

Then push like normal with hg push or with TortoiseHg. Mercurial will now send all the commits (including all branches) to the repository on Bitbucket.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top