[PATCH] color: document the possibility to colourise tabs in diffs
raf at durin42.com
Tue Oct 7 12:15:01 CDT 2014
On Fri, Oct 03, 2014 at 04:19:33PM -0400, Jordi Gutiérrez Hermoso wrote:
> # HG changeset patch
> # User Jordi Gutiérrez Hermoso <jordigh at octave.org>
> # Date 1408562377 14400
> # Wed Aug 20 15:19:37 2014 -0400
> # Node ID 7b18366b12d6081bc78bb2beb98bdcb71018ef69
> # Parent 78c916f24dd99a56e4c29153a5df3bd7d1c40edd
> color: document the possibility to colourise tabs in diffs
This was pushed as b07fd3ac8882.
> This is a no-op change that simply suggests that tabs can be
> colourised, but defaults to no colour effects for tabs. This
> complements cset c343557a8442.
> Like the similar effects for phases from f8e2aebbb24c, we set the
> default effects to '' instead of None, so that this is a true noop
> change. Otherwise, the diff.tab effect would override (i.e.
> neutralise) the effect of the surrounding label.
> diff --git a/hgext/color.py b/hgext/color.py
> --- a/hgext/color.py
> +++ b/hgext/color.py
> @@ -11,7 +11,7 @@ This extension modifies the status and r
> to their output to reflect file status, the qseries command to add
> color to reflect patch status (applied, unapplied, missing), and to
> diff-related commands to highlight additions, removals, diff headers,
> -and trailing whitespace.
> +tabs, and trailing whitespace.
> Other effects in addition to color, like bold and underlined text, are
> also available. By default, the terminfo database is used to find the
> @@ -61,6 +61,7 @@ effects may be overridden from your conf
> diff.deleted = red
> diff.inserted = green
> diff.changed = white
> + diff.tab =
> diff.trailingwhitespace = bold red_background
> # Blank so it inherits the style of the surrounding label
> @@ -279,6 +280,7 @@ except ImportError:
> 'diff.file_b': 'green bold',
> 'diff.hunk': 'magenta',
> 'diff.inserted': 'green',
> + 'diff.tab': '',
> 'diff.trailingwhitespace': 'bold red_background',
> 'changeset.public' : '',
> 'changeset.draft' : '',
> Mercurial-devel mailing list
> Mercurial-devel at selenic.com
More information about the Mercurial-devel