Re: [RFC] Syntax highlighting for combined diff

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

 



Junio C Hamano wrote:
> Jakub Narebski <jnareb@xxxxxxxxx> writes:
> 
> > Do I understand code correctly, and the last '+' or '-'
> > in the parents column means?
> >
> >         for (i = 0; i < ecbdata->nparents && len; i++) {
> >                 if (line[i] == '-')
> >                         color = DIFF_FILE_OLD;
> >                 else if (line[i] == '+')
> >                         color = DIFF_FILE_NEW;
> >         }
> >
> > Anyone who wrote this code, could you answer me, please?
> 
> The "up to ecbdata->nparents" is Johannes in cd112ce.  But you
> are looking at a wrong code, I am afraid, if your original
> question was about the combined format (there is a comment about
> the codepath dealing only with two-way diffs by Johannes, above
> the part you quoted).  The output for combined diff is coming
> from combine-diff.c:dump_sline().

I was asking both about combined diff format, and how it is colored
by git-diff --color, to add colored combined diff output to gitweb.

> Combined diff output logic pretty much guarantees that you never
> will see plus and minus on the same line.

That's enough for me.

Any other ideas how combined commitdiff should look like in gitweb?
-- 
Jakub Narebski
Poland
-
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]