On Sat, Oct 3, 2015 at 5:32 PM, Matthieu Moy <Matthieu.Moy@xxxxxxxxxxxxxxx> wrote: > Karthik Nayak <karthik.188@xxxxxxxxx> writes: > >> Introduce format_ref_array_item() which will output the details of a >> given ref_array_item as per the given format and quote_style to the >> given strbuf. > > Why do you need it in this series and you could do without for tag? > > Going through PATCH 8/9, I guess there's something related to --column, > but tag also has --column so I'm puzzled. > The problem is with colors which tag.c doesn't use by default. Here we need to print colors only if we're printing to a tty which supports colors. which does not play well with the implementation of --column as done in tag.c. Where, If I'm not wrong the --column option captures all output, formats it and then prints it to stdout. Hence when using colors, we're told that the printing isn't done to a tty which supports colors, hence we lose out on colors. I was trying something where we have a variable which knows when the column option is used and hence explicitly lets us use colors, but seemed like a mess. This was a clean of going about it. -- Regards, Karthik Nayak -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html