[PATCH 2 of 3] help: modify template help to use a comma instead of newline for extras

Augie Fackler raf at durin42.com
Sat Dec 14 10:57:07 CST 2013


On Thu, Nov 21, 2013 at 04:04:24PM -0500, Matthew Turk wrote:
> # HG changeset patch
> # User Matthew Turk <matthewturk at gmail.com>
> # Date 1385066846 18000
> #      Thu Nov 21 15:47:26 2013 -0500
> # Node ID 547837e59d439af3c907931ca65cab911d00dfe3
> # Parent  e4c89fff1cc57f532d43d0015445ab44a739f6d7
> help: modify template help to use a comma instead of newline for extras.
>
> Newlines need different escaping, and this is a more terse example of extras in
> template help.
>
> diff -r e4c89fff1cc5 -r 547837e59d43 mercurial/help/templates.txt
> --- a/mercurial/help/templates.txt	Thu Nov 21 15:46:49 2013 -0500
> +++ b/mercurial/help/templates.txt	Thu Nov 21 15:47:26 2013 -0500
> @@ -105,4 +105,4 @@
>
>  - Display the contents of the 'extra' field, one per line::

Is this output really still one per line?

>
> -  $ hg log -r 0 --template "{join(extras, '\n')}\n"
> +  $ hg log -r 0 --template "{join(extras, ', ')}\n"
> _______________________________________________
> Mercurial-devel mailing list
> Mercurial-devel at selenic.com
> http://selenic.com/mailman/listinfo/mercurial-devel


More information about the Mercurial-devel mailing list