[PATCH 1 of 5 V3] templates: add support for filelog webcommand in json style

Yuya Nishihara yuya at tcha.org
Mon Jun 20 10:29:49 EDT 2016


On Mon, 20 Jun 2016 11:25:24 +0200, Laura Médioni wrote:
> # HG changeset patch
> # User Laura Médioni <laura.medioni at logilab.fr>
> # Date 1464946102 -7200
> #      Fri Jun 03 11:28:22 2016 +0200
> # Node ID 53f73556559ade2e726e9355b521dcbd95ae4dae
> # Parent  4e6e280e238fa885df9e0e600dc5915a71c8a37a
> templates: add support for filelog webcommand in json style

Queued the first 4 patches, thanks.

I have some minor questions, so please send a follow-up patch if necessary.

> --- a/mercurial/templates/json/map
> +++ b/mercurial/templates/json/map
> @@ -7,14 +7,17 @@ changelog = changelist.tmpl
>  shortlog = changelist.tmpl
>  changelistentry = '\{
>    "node": {node|json},
>    "date": {date|json},
>    "desc": {desc|utf8|json},
> +  "branch": {if(branch, branch%changesetbranch, "default"|json)},

It seems wrong to assume unspecified branch as "default", but we already
have this bits in json/map. So it should be okay for now.

> +  "parents": [{if(allparents, join(allparents%changesetparent, ", "),
> +                  join(parent%changesetparent, ", "))}]

Confirmed 'parent' of commonentry == 'allparents' of changelistentry.
That's unfortunate we have different 'parent' keywords.


More information about the Mercurial-devel mailing list