[PATCH 01 of 12] localrepo: add an unused dictionary for arbitrary labels
gregory.szorc at gmail.com
Thu Aug 21 13:29:12 CDT 2014
On 8/18/14 2:17 PM, Sean Farley wrote:
> # HG changeset patch
> # User Sean Farley <sean.michael.farley at gmail.com>
> # Date 1396216512 18000
> # Sun Mar 30 16:55:12 2014 -0500
> # Node ID ed72c4bcbbbcab7f75f6b86fee6c67aa45590e7c
> # Parent 8dda6f6ff564d8fe6ac7b8ce4c74eb9bfb5de14a
> localrepo: add an unused dictionary for arbitrary labels
I wanted to say how much I enjoy what you are trying to do here. This
approach should drastically lower the barrier to robust implementations
of things like remote refs.
I recently implemented an extension for Mozilla (firefoxtree) that
implements a light version of remote refs. Essentially, when you pull
from a known Firefox repository (identified by URL), it creates a local
tag with the name of that repo.
I had to jump through hoops  to implement this properly. The tags
APIs are far from robust and writing local tags would result in multiple
lines in the localtags file for a given tag. I had to hack around this.
It is very ugly.
I like the approach in this patch series of using a two-level dict to
identify "labels". My extension could easily invent a "firefox"
namespace and put its node mappings there. The separation into multiple
namespaces makes the filtering problem go away and makes extension code
easier to write.
This patch series seems to start solving some problems I have with the
existing tags/bookmarks implementations.
More information about the Mercurial-devel