[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: Blame improvements - line range; deleted lines [was: svn commit: r1491445 ...]

From: Daniel Shahaf <danielsh_at_elego.de>
Date: Wed, 12 Jun 2013 17:52:21 +0200

Julian Foad wrote on Wed, Jun 12, 2013 at 16:41:59 +0100:
> Prabhu wrote:
>
> > On 06/12/2013 05:55 PM, Julian Foad wrote:
> >> I have thought before that it would sometimes be useful to include blame
> >> information on the gaps between lines.  For each gap between adjacent lines (and
> >> before the first and after the last line), there is a revision in which any text
> >> between these two lines was deleted.
> >>
> >> Example: blame -r1:30 foo.c_at_30 could produce these (revnum | line-text)
> >> pairs:
> >>     r20 | "int main()"
> >>     r20 | "{"
> >>     r25 | NULL
> >>     r30 | "    return 0;"
> >>     r20 | "}"
> >>
> >> where NULL means some line(s) were at this position in r24 but nothing was
> >> here in r25 up to the revision being blamed.
> >
> > How would we handle/show if the line existed in 24r but not in r25..
> > Again existed in r27 and removed in r29 ? I can't think of the UI...
>
> Blame is only intended to identify the most recent change to each line.  In this case, we would identify the most recent change of the inter-line gap, so that would be r29.  I think that is useful and consistent with the way Blame works already.
>
> As a different example, if there were two lines in that "gap" in r24, and one of them was removed in r25, and the second one was removed in r29, then again we'd only show "r29" for the gap, because that is the most recent change in that gap.

What about an optional output mode that prints the gaps only, but all of
them?

e.g., if I do 'blame -r 25:29', the optional output mode would print all
lines added in r26 or in r27 or in r28 that are not present in r29, and
only them.
Received on 2013-06-12 17:52:59 CEST

This is an archived mail posted to the Subversion Dev mailing list.