Patchwork revset: document the `revset(...)` syntax

login
register
mail settings
Submitter Boris Feld
Date Oct. 1, 2018, 4:22 p.m.
Message ID <35ddc91a3298a8c1e4b0.1538410962@localhost.localdomain>
Download mbox | patch
Permalink /patch/35253/
State Superseded
Headers show

Comments

Boris Feld - Oct. 1, 2018, 4:22 p.m.
# HG changeset patch
# User Boris Feld <boris.feld@octobus.net>
# Date 1538056800 -7200
#      Thu Sep 27 16:00:00 2018 +0200
# Node ID 35ddc91a3298a8c1e4b037dd091799753b32ce42
# Parent  a269fa55467e4952a8cb9d1f8743dd12e1a57943
# EXP-Topic revset-doc
# Available At https://bitbucket.org/octobus/mercurial-devel/
#              hg pull https://bitbucket.org/octobus/mercurial-devel/ -r 35ddc91a3298
revset: document the `revset(...)` syntax

Since this is not implemented as a revset, it was missing proper
documentation. We explicitly introduce one.
Yuya Nishihara - Oct. 2, 2018, 12:14 p.m.
On Mon, 01 Oct 2018 18:22:42 +0200, Boris Feld wrote:
> # HG changeset patch
> # User Boris Feld <boris.feld@octobus.net>
> # Date 1538056800 -7200
> #      Thu Sep 27 16:00:00 2018 +0200
> # Node ID 35ddc91a3298a8c1e4b037dd091799753b32ce42
> # Parent  a269fa55467e4952a8cb9d1f8743dd12e1a57943
> # EXP-Topic revset-doc
> # Available At https://bitbucket.org/octobus/mercurial-devel/
> #              hg pull https://bitbucket.org/octobus/mercurial-devel/ -r 35ddc91a3298
> revset: document the `revset(...)` syntax
> 
> Since this is not implemented as a revset, it was missing proper
> documentation. We explicitly introduce one.
> 
> diff --git a/mercurial/help/revisions.txt b/mercurial/help/revisions.txt
> --- a/mercurial/help/revisions.txt
> +++ b/mercurial/help/revisions.txt
> @@ -143,6 +143,12 @@ The following predicates are supported:
>  
>  .. predicatesmarker
>  
> +``revset(set)``
> +
> +  The content of this special predicate will be strictly interpreted as a
> +  revset. For example ``revset(id(0))`` will interpret "id(0)" without
> +  possible ambiguity with a possible "id(0)" bookmark or tags.

We can instead add the `revset()` function, which is basically the same as
present() but no try-except block.

Patch

diff --git a/mercurial/help/revisions.txt b/mercurial/help/revisions.txt
--- a/mercurial/help/revisions.txt
+++ b/mercurial/help/revisions.txt
@@ -143,6 +143,12 @@  The following predicates are supported:
 
 .. predicatesmarker
 
+``revset(set)``
+
+  The content of this special predicate will be strictly interpreted as a
+  revset. For example ``revset(id(0))`` will interpret "id(0)" without
+  possible ambiguity with a possible "id(0)" bookmark or tags.
+
 Aliases
 =======