hg-git plugin, problem with local cloning: bookmarks

Kevin Bullock kbullock+mercurial at ringworld.org
Wed Aug 31 21:45:29 UTC 2016


> On Aug 31, 2016, at 15:11, Uwe Brauer <oub at mat.ucm.es> wrote:
> 
>> Git only clones the master branch (or whatever the remote says its
>> HEAD is), so your local copy actually doesn't have the other Git
>> branches in it. You can get them by running `git fetch` in the Git
>> clone, then re-clone locally with hg.
> 
> Thanks but
> 
> git fetch 
> 
> Didn't do anything.
> 
> On the other hand if the branches are not present why did
> git branch -a
> 
> Listed them?

Ahh, it looks like cloning a repo only creates bookmarks for the remote's own branches. So if you were to `git checkout` each of the branches in your local clone, and then re-clone locally with hg, you'd get all the branches.

I'm not sure what the right behavior is there, but we might be able to make hg-git smarter about that somehow. You're welcome to file an issue at: <https://bitbucket.org/durin42/hg-git/issues>

pacem in terris / мир / शान्ति / ‎‫سَلاَم‬ / 平和
Kevin R. Bullock




More information about the Mercurial mailing list