Patchwork [2,of,3] color: give colours to the grep.inserted and grep.deleted labels

login
register
mail settings
Submitter Jordi Gutiérrez Hermoso
Date Feb. 15, 2019, 8:49 p.m.
Message ID <9e2f595cf719f2dd8634.1550263776@chloe>
Download mbox | patch
Permalink /patch/38771/
State Superseded
Headers show

Comments

Jordi Gutiérrez Hermoso - Feb. 15, 2019, 8:49 p.m.
# HG changeset patch
# User Jordi Gutiérrez Hermoso <jordigh@octave.org>
# Date 1550263402 18000
#      Fri Feb 15 15:43:22 2019 -0500
# Node ID 9e2f595cf719f2dd863485067517f4f6c05dee73
# Parent  b5464436e4acdd1893ee86e5aa03f1d69ce4c4c5
color: give colours to the grep.inserted and grep.deleted labels

I find the "bold" makes it stand out a bit more when the green is next
to the line number.

Note that these labels are applied before the grep.change label, which
is now disabled. To get the old colour, users can restore

    [color]
    grep.change = green dim

to their hgrc.

Patch

diff --git a/mercurial/color.py b/mercurial/color.py
--- a/mercurial/color.py
+++ b/mercurial/color.py
@@ -78,11 +78,12 @@  except ImportError:
     'grep.match': 'red bold',
     'grep.linenumber': 'green',
     'grep.rev': 'green',
-    'grep.change': 'green',
     'grep.sep': 'cyan',
     'grep.filename': 'magenta',
     'grep.user': 'magenta',
     'grep.date': 'magenta',
+    'grep.inserted': 'green bold',
+    'grep.deleted': 'red bold',
     'bookmarks.active': 'green',
     'branches.active': 'none',
     'branches.closed': 'black bold',