Re: [RFC/PATCH 02/11] ref-filter: add 'colornext' atom

2015-08-01 Thread Karthik Nayak
On Thu, Jul 30, 2015 at 9:47 PM, Junio C Hamano gits...@pobox.com wrote: Jacob Keller jacob.kel...@gmail.com writes: On Wed, Jul 29, 2015 at 2:30 PM, Matthieu Moy matthieu@grenoble-inp.fr wrote: Eric Sunshine sunsh...@sunshineco.com writes: Also, please explain here and in the commit

Re: [RFC/PATCH 02/11] ref-filter: add 'colornext' atom

2015-07-30 Thread Junio C Hamano
Jacob Keller jacob.kel...@gmail.com writes: On Wed, Jul 29, 2015 at 2:30 PM, Matthieu Moy matthieu@grenoble-inp.fr wrote: Eric Sunshine sunsh...@sunshineco.com writes: Also, please explain here and in the commit message why this highly specialized colorizer ('colornext'), is needed even

Re: [RFC/PATCH 02/11] ref-filter: add 'colornext' atom

2015-07-29 Thread Matthieu Moy
Eric Sunshine sunsh...@sunshineco.com writes: Also, please explain here and in the commit message why this highly specialized colorizer ('colornext'), is needed even though a more general purpose one ('color') is already available. It is needed in the current form to allow

Re: [RFC/PATCH 02/11] ref-filter: add 'colornext' atom

2015-07-29 Thread Eric Sunshine
On Tuesday, July 28, 2015, Karthik Nayak karthik@gmail.com wrote: The 'colornext' atom allows us to color only the succeeding atom with a particular color. This resets any previous color preferences set. It is not compatible with `padright`. This is required for printing formats like `git

Re: [RFC/PATCH 02/11] ref-filter: add 'colornext' atom

2015-07-29 Thread Jacob Keller
On Wed, Jul 29, 2015 at 2:30 PM, Matthieu Moy matthieu@grenoble-inp.fr wrote: Eric Sunshine sunsh...@sunshineco.com writes: Also, please explain here and in the commit message why this highly specialized colorizer ('colornext'), is needed even though a more general purpose one ('color')

Re: [RFC/PATCH 02/11] ref-filter: add 'colornext' atom

2015-07-28 Thread Matthieu Moy
Karthik Nayak karthik@gmail.com writes: --- a/t/t6302-for-each-ref-filter.sh +++ b/t/t6302-for-each-ref-filter.sh @@ -133,4 +133,20 @@ test_expect_success 'reverse version sort' ' test_cmp expect actual ' +get_color () +{ + git config --get-color no.such.slot $1 +} +

[RFC/PATCH 02/11] ref-filter: add 'colornext' atom

2015-07-28 Thread Karthik Nayak
The 'colornext' atom allows us to color only the succeeding atom with a particular color. This resets any previous color preferences set. It is not compatible with `padright`. This is required for printing formats like `git branch -vv` where the upstream is colored in blue. Mentored-by: Christian

Re: [RFC/PATCH 02/11] ref-filter: add 'colornext' atom

2015-07-28 Thread Christian Couder
On Tue, Jul 28, 2015 at 8:56 AM, Karthik Nayak karthik@gmail.com wrote: @@ -712,6 +713,15 @@ static void populate_value(struct ref_array_item *ref) v-modifier_atom = 1; v-pad_to_right = 1; continue; + }

Re: [RFC/PATCH 02/11] ref-filter: add 'colornext' atom

2015-07-28 Thread Karthik Nayak
On Tue, Jul 28, 2015 at 2:43 PM, Christian Couder christian.cou...@gmail.com wrote: On Tue, Jul 28, 2015 at 8:56 AM, Karthik Nayak karthik@gmail.com wrote: @@ -712,6 +713,15 @@ static void populate_value(struct ref_array_item *ref) v-modifier_atom = 1;

Re: [RFC/PATCH 02/11] ref-filter: add 'colornext' atom

2015-07-28 Thread Karthik Nayak
On Tue, Jul 28, 2015 at 2:15 PM, Matthieu Moy matthieu@grenoble-inp.fr wrote: Karthik Nayak karthik@gmail.com writes: --- a/t/t6302-for-each-ref-filter.sh +++ b/t/t6302-for-each-ref-filter.sh @@ -133,4 +133,20 @@ test_expect_success 'reverse version sort' ' test_cmp expect