W3C home > Mailing lists > Public > www-style@w3.org > June 2013

Re: Github mirror: how does it work?

From: Peter Linss <peter.linss@hp.com>
Date: Tue, 25 Jun 2013 11:20:18 -0700
Cc: "www-style@w3.org" <www-style@w3.org>, Arthur Barstow <art.barstow@nokia.com>, Charles McCathie Nevile <chaals@yandex-team.ru>
Message-Id: <FA461663-13D6-4C97-AFE8-4C6284657957@hp.com>
To: Dimitri Glazkov <dglazkov@google.com>
On Jun 19, 2013, at 9:18 AM, Dimitri Glazkov wrote:

> Hello Stylish People!
> 
> I just realized you guys have a beautiful github mirror of the dvcs
> repo: https://github.com/w3c
> 
> How do you use it? What is the dark magic behind the bridge between Hg
> and Git? I am asking this question because I am sort of wondering if
> we WebApps peeps could do something similar. Github's reviewing and
> multiple-contributor management facilities are pretty much tops.
> 
> :DG<
> 

Hi Dimitri,

if your Hg repo is on dvcs.w3.org then the best bet is to ask the sysadmins at w3.org to setup the mirror for you. We also mirror our Hg repos from hg.csswg.org which I set up myself. In either case, the Hg to Git bridge is done with HgGit ( http://hg-git.github.io/ ). 

Note that with the current technology available to us, the bridge is not bidirectional. One of your repositories will be canonical, the other will be a read-only mirror. For the CSSWG, our Hg repos are canonical and the GitHub mirrors are read-only. When we merge pull requests the merger has to use HgGit to pull the PR into a local Hg repository, then push from there to the canonical Hg repo. Other groups have decided to make their GitHub repos canonical which allows them to merge PRs directly on GitHub, they just can't push to the Hg repo anymore.

I've been exploring what it would take to make the bridge bi-directional, allowing pushing to either repository. There have been some attempts which work for simple cases, but there are gotchas dealing with branches...

Peter
Received on Tuesday, 25 June 2013 18:20:41 UTC

This archive was generated by hypermail 2.3.1 : Monday, 2 May 2016 14:39:12 UTC