Patchwork [2,of,2] color: document the possibility to colourise tabs in diffs

login
register
mail settings
Submitter Jordi Gutiérrez Hermoso
Date Aug. 24, 2014, 10:22 p.m.
Message ID <258f682b167cdbbbc65e.1408918937@Iris>
Download mbox | patch
Permalink /patch/5576/
State Superseded
Commit b07fd3ac8882f24b3f63cb80836ebd9532da94f3
Headers show

Comments

Jordi Gutiérrez Hermoso - Aug. 24, 2014, 10:22 p.m.
# HG changeset patch
# User Jordi Gutiérrez Hermoso <jordigh@octave.org>
# Date 1408562377 14400
#      Wed Aug 20 15:19:37 2014 -0400
# Node ID 258f682b167cdbbbc65eeb0ad37a824e6650c42f
# Parent  a028ddacb2daea2b4fe1db75f76f5ca0305f41c6
color: document the possibility to colourise tabs in diffs

This is a no-op change that simply suggests that tabs can be
colourised, but defaults to no colour effects for tabs.
Pierre-Yves David - Sept. 17, 2014, 11:54 p.m.
On 08/24/2014 03:22 PM, Jordi Gutiérrez Hermoso wrote:
> # HG changeset patch
> # User Jordi Gutiérrez Hermoso <jordigh@octave.org>
> # Date 1408562377 14400
> #      Wed Aug 20 15:19:37 2014 -0400
> # Node ID 258f682b167cdbbbc65eeb0ad37a824e6650c42f
> # Parent  a028ddacb2daea2b4fe1db75f76f5ca0305f41c6
> color: document the possibility to colourise tabs in diffs
>
> This is a no-op change that simply suggests that tabs can be
> colourised, but defaults to no colour effects for tabs.

I would accept this change if it did not break the test-diff-color.t 
test (I've no idea why)

Patch

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
@@ -45,6 +45,7 @@  Default effects may be overridden from y
   diff.deleted = red
   diff.inserted = green
   diff.changed = white
+  diff.tab = none
   diff.trailingwhitespace = bold red_background
 
   resolve.unresolved = red bold
@@ -255,6 +256,7 @@  except ImportError:
            'diff.file_b': 'green bold',
            'diff.hunk': 'magenta',
            'diff.inserted': 'green',
+           'diff.tab': 'none',
            'diff.trailingwhitespace': 'bold red_background',
            'diffstat.deleted': 'red',
            'diffstat.inserted': 'green',