[PATCH 2 of 2] doc: improves merge-tools example with a vimdiff one

Mads Kiilerich mads at kiilerich.com
Sun Sep 2 18:03:00 CDT 2012


Pierre-Yves David wrote, On 08/31/2012 09:34 PM:
> # HG changeset patch
> # User Pierre-Yves David <pierre-yves.david at logilab.fr>
> # Date 1343908294 -7200
> # Branch stable
> # Node ID b0c46da50e50eb93ca61c865a38e711705172a0a
> # Parent  3b955dc3df50e296e19b244f85464f68121fb292
> doc: improves merge-tools example with a vimdiff one
>
> The vimdiff example show the `check` argument and explicit way `priority` works.
> Another benefit is to have the vimdiff configuration directly available in the
> doc. This is valuable as vimdiff is a common request from user.

I'm -0 on this.

We have vimdiff in contrib/mergetools.hgrc, and it should thus be easily 
available without further configuration. The worst case is that the user 
has to change the priority. There should thus not be any need for 
showing a 'full' vimdiff configuration in the documentation.

It is also not feasible to show examples for all settings ... and if we 
want to show examples then we should refer to mergetools.hgrc.

> diff --git a/mercurial/help/config.txt b/mercurial/help/config.txt
> --- a/mercurial/help/config.txt
> +++ b/mercurial/help/config.txt
> @@ -809,6 +809,13 @@
>     myHtmlTool.regkey = Software\FooSoftware\HtmlMerge
>     myHtmlTool.priority = 1
>   
> +  # Define fallback tool
> +  vimdiff.args=$local $other $base
> +  # detect unchanged files as potential conflict
> +  vimdiff.check=changed

check=changed will not do what this comment says.

/Mads

> +  # give priority lower than gui tool
> +  vimdiff.priority=0
> +
>   Supported arguments:
>   
>   ``priority``
> _______________________________________________
> Mercurial-devel mailing list
> Mercurial-devel at selenic.com
> http://selenic.com/mailman/listinfo/mercurial-devel



More information about the Mercurial-devel mailing list