On 10/08/2013 04:18 PM, Chris J Arges wrote: > Add colorized text for git blame when color.interactive is enabled. > This work is based on the colorization code in builtin/clean.c. >
Another way to color blame, would be by commit, not by row.
Try "git gui blame <file>", to see what I mean. The colorisation
would be per commit and not by line.
Though I guess that's a lot of more work, but I'd personally find it
better, for what it's worth.
>
> +static const char *blame_get_color(enum color_blame ix)
> +{
> + if (want_color(blame_use_color))
> + return blame_colors[ix];
> + return "";
> +}
The only occurence of blame_get_color is in blame_print_color, so why
not move it in there?
> +
> +static void blame_print_color(enum color_blame ix)
> +{
> + printf("%s", blame_get_color(ix));
> +}
> +
> static const char *format_time(unsigned long time, const char *tz_str,
Thanks,
Stefan
signature.asc
Description: OpenPGP digital signature

