yuja added a comment.
> +@predicate('merge(*withbranch)', safe=True) > > def merge(repo, subset, x): > > - """Changeset is a merge changeset. + """Changeset is a merge changeset + + All merge revisions are returned by default. If one or more "withbranch" + names are provided only merges with those branches (i.e. whose + second parent belongs to one of those branches) will be returned. I understand this will be useful in a certain branch strategy, but the proposed syntax is hardly extensible. Maybe it can be a non-wildcard argument of `stringmatcher` type so we can at least add another option later. Any thoughts? Do anyone love this feature? If we had a syntax to filter revisions by sub expression, this and the samebranch option could be expressed as follows: merge() & filter($a, p2($a) & branch("...")) merge() & filter($a, samebranch(parents($a))) where filter(argname, boolean-expr) This is much more expressive (or verbose) and can support other types of branches, but is hard to implement. REPOSITORY rHG Mercurial REVISION DETAIL https://phab.mercurial-scm.org/D5495 To: angel.ezquerra, #hg-reviewers Cc: yuja, mercurial-devel _______________________________________________ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel