Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [jgit-dev] RevSort#COMMIT_TIME_DESC confusion

On 15.08.2011 17:59, Marc Strapetz wrote:
> On 13.08.2011 21:05, Shawn Pearce wrote:
>> On Sat, Aug 13, 2011 at 10:15, Marc Strapetz <marc.strapetz@xxxxxxxxxxx> wrote:
>>>>> Should I keep them local to our project or submit as patch? In
>>>>> latter case, any suggestions where to place that methods?
>>>> Operations like `git branch --contains` need something like this. So
>>>> we would appreciate a contribution to RevWalk or a new class in that
>>>> same package that makes this operation easy in JGit.

I've now uploaded two patches addressing this issue:,4537,4538

4537 is the interesting one, which introduces a new queue extending
DateRevQueue which discards commits that are ancestors of commits which
are common to all start commits. The queue has to be installed for a
RevWalk and thereby puts some restrictions on the configuration of the
RevWalk. However, it may be combined with different Commit sorting,
especially topological one. This opens up some more applications related
to common ancestors: for instance, it helped me to speed up detection of
pushable/mergable commits (git status' "diverged" commits).

The patches are working (at least for the tests), still they are more or
less drafts. If this approach is a way to go, I'll continue to refine them.

Best regards,
Marc Strapetz
syntevo GmbH

Back to the top