[PATCH STABLE] revsets: add docs for '%' operator

Sean Farley sean at farley.io
Wed Apr 27 16:26:53 EDT 2016


Sean Farley <sean at farley.io> writes:

> # HG changeset patch
> # User Sean Farley <sean at farley.io>
> # Date 1461787703 25200
> #      Wed Apr 27 13:08:23 2016 -0700
> # Branch stable
> # Node ID e08a7fd47208aed37d6b7d5a6414b444c61b6393
> # Parent  cfcd065cae29673c180892ae692e986661a4adc6
> # EXP-Topic doc-only-revset
> revsets: add docs for '%' operator
>
> diff --git a/mercurial/help/revsets.txt b/mercurial/help/revsets.txt
> --- a/mercurial/help/revsets.txt
> +++ b/mercurial/help/revsets.txt
> @@ -40,10 +40,14 @@ These are the supported infix operators:
>    forms: ``x | y`` and ``x + y``.
>  
>  ``x - y``
>    Changesets in x but not in y.
>  
> +``x % y``
> +  Changesets that are ancestors of x but not ancestors of y (i.e. ::x - ::y).
> +  This is shorthand notation for ``only(x, y)`` (see below).

I'll send a V2 with feedback gathered on #mercurial. Probably something
like this:

``x % y``
  Changesets that are ancestors of x but not ancestors of y (i.e. ::x - ::y).
  This is shorthand notation for ``only(x, y)`` (see below). The second
  argument is optional. If y is not provided, then ``x %`` will mod out
  the ancestors of the other heads in the repo.


More information about the Mercurial-devel mailing list