diff.c: fix a graph output bug
PATCH 1/1 diff.c: fix a graph output bug
From: Bo Yang <[email protected]>
Ouput the line_prefix ahead of color sequence.
--- diff.c | 3 +-- 1 files changed, 1 insertions(+), 2 deletions(-)
diff.c +1 -2
@@ -2627,8 +2627,7 @@ static void fill_metainfo(struct strbuf *msg, (!fill_mmfile(&mf, two) && diff_filespec_is_binary(two))) abbrev =40 ; } -strbuf_addf (msg,"%s%sindex %s.." , set, - line_prefix, +strbuf_addf (msg,"%s%sindex %s.." , line_prefix, set,find_unique_abbrev (one->sha1, abbrev));strbuf_addstr (msg,find_unique_abbrev (two->sha1, abbrev));if (one->mode == two->mode)
Signature · 1 line
1.7.0.2.273.gc2413.dirty
Quoted 3 lines · [email protected] writes:
From: Bo Yang <[email protected]>
Ouput the
line_prefixahead of color sequence.
Justification for the patch, and/or a better bug description ("when run with this combination of options, X gets painted in that color that is not meant to be used for X") please?
Quoted 27 lines
Signed-off-by Bo Yang <[email protected]>--- diff.c | 3 +-- 1 files changed, 1 insertions(+), 2 deletions(-)diff.c +1
-2@@ -2627,8 +2627,7 @@ static void fill_metainfo(struct strbuf *msg, (!fill_mmfile(&mf, two) && diff_filespec_is_binary(two))) abbrev =40 ; } -strbuf_addf (msg,"%s%sindex %s.." , set, - line_prefix, +strbuf_addf (msg,"%s%sindex %s.." , line_prefix, set,find_unique_abbrev (one->sha1, abbrev));strbuf_addstr (msg,find_unique_abbrev (two->sha1, abbrev));if (one->mode == two->mode)Signature · 6 lines
1.7.0.2.273.gc2413.dirty -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
Quoted 11 lines · Junio C Hamano
Quoted 3 lines · [email protected] writes:
From: Bo Yang <[email protected]>
Ouput the
line_prefixahead of color sequence.Justification for the patch, and/or a better bug description ("when run with this combination of options, X gets painted in that color that is not meant to be used for X") please?
Quoted 2 lines
Signed-off-by Bo Yang <[email protected]>
Perhaps something like this?
From: Bo Yang <[email protected]>
Date: Thu, 8 Jul 2010 23:12:34 +0800
Subject: [PATCH] diff.c: fix a graph output bug
When --graph is in effect, the line-prefix typically has colored graph line segments and ends with reset. The color sequence "set" given to this function is for showing the metainfo part of the patch text and
(1) it should not be applied to the graph lines, and (2) it will be reset at the end of line_prefix so it won't be effect anyway.
--- diff.c | 3 +-- 1 files changed, 1 insertions(+), 2 deletions(-)
...
Quoted 1 line · Junio C Hamano
reset at the end of
line_prefixso it won't be effect anyway.
s/effect/affected/ ?
nazri
Quoted 4 lines · Nazri Ramliy
Quoted 1 line · Junio C Hamano
reset at the end of
line_prefixso it won't be effect anyway.s/effect/affected/ ?
Thanks for spotting. I meant to say "won't be in effect".
Hi Junio,
Quoted 12 lines · Junio C Hamano
Perhaps something like this?
From: Bo Yang <[email protected]>
Date: Thu, 8 Jul 2010 23:12:34 +0800
Subject: [PATCH]diff.c: fix a graph output bugWhen --graph is in effect, the line-prefix typically has colored graph line segments and ends with reset. The color sequence "set" given to this function is for showing the metainfo part of the patch text and
(1) it should not be applied to the graph lines, and (2) it will be reset at the end ofline_prefixso it won't be effect anyway.
Quoted 7 lines
Signed-off-by Bo Yang <[email protected]>Signed-off-by Junio C Hamano <[email protected]>---
diff.c | 3 +--1 files changed, 1 insertions(+), 2 deletions(-)...
Hmm, your description is great, thanks a lot! And please apply this patch, thanks!
Signature · 5 lines
Regards! Bo ---------------------------- My blog: http://blog.morebits.org Why Git: http://www.whygitisbetterthanx.com/