Re: [PATCH 1/2] Added basic color support to git add --interactive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



El 23/10/2007, a las 8:41, Jeff King escribió:

On Tue, Oct 23, 2007 at 08:28:28AM +0200, Wincent Colaiuta wrote:

I did too, where you add a third, optional "trailer" parameter to the
function where you pass the newline if there is one (following the style of
the functions in color.c). Pasting it below.

The problem with that approach is that you can only send in a single
line at a time (with the newline detached!), so it makes life harder for
the caller. E.g., there is at least one spot that uses a here-doc with
many lines; splitting that into a bunch of print_ansi_color calls would
be unnecessarily ugly.

Yes, I agree that it complicates things for the caller. I was just copying the model found in color.c; but seeing as this is Perl splitting into lines inside the printing function would be straightforward.

Cheers,
Wincent



-
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

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux