[PATCH 0 of 2 WIP] generic facility to filter revisions from a revlog
Matt Mackall
mpm at selenic.com
Fri Jul 13 13:12:57 CDT 2012
On Fri, 2012-06-29 at 20:07 +0300, Idan Kamara wrote:
> This series is an attempt to add a generic facility to hide revisions from
> a revlog. It will be used to expose a filtered changelog.
[backlog = 124]
This seems like a good start.
> The approach I've taken is to add two classes:
>
> 1) filteredrevlog - this class accepts an existing revlog and two sets of
> filtered revs/nodes.
Seems like it'd be better to accept just one set and generate the other
(if needed).
> Some function results can be filtered simply by removing
> elements from the result. Others (like heads()) are a bit more complicated.
> 2) filteredchangelog - this class inherits from filteredrevlog, accepts an
> existing changelog and two sets as above.
>
> In localrepo we keep these two sets and instantiate a filteredchangelog
> via filter/unfilter functions. I haven't completely figured out how and when
> other parts of the code (non extensions) are going to add things to filter
> (ideally these shouldn't be centered in one big function).
>
> The end result is that revisions aren't visible to the outside world unless
> explicitly specified.
>
> Some things that still need checking/fixing:
> - eliminate '[x]range(len(repo))' in favor of 'list/iter(repo)'
Patches for that can go in any time.
> - check interaction with various caches
> - fix revsets
> _______________________________________________
> Mercurial-devel mailing list
> Mercurial-devel at selenic.com
> http://selenic.com/mailman/listinfo/mercurial-devel
--
Mathematics is the supreme nostalgia of our time.
More information about the Mercurial-devel
mailing list