Re: Following renames
- From
- Marco Costalba <mcostalba@gmail.com>
- Date
- Mar 27, 2006, 11:55 UTC
- Message-ID
- <e5bfff550603270355s4b71c306hb4cb2b96eafd0f6e@mail.gmail.com>
- In-Reply-To
- <Pine.LNX.4.64.0603270005330.15714@g5.osdl.org>
On 3/27/06, Linus Torvalds <torvalds@osdl.org> wrote:
> > In contrast, git-whatchanged will start outputting the recent changes > immediately. >
To integrate git-whatchanged like functionality with filter on a specific code region, the Linus original request, I am wondering about something like this:
A new git-diff-tree option --range=a..b to delimit a region, identified by code lines bounduaries.
As example
git-diff-tree --range=10..15 HEAD -- <path>
Coud give these answers, added to standard git-diff-tree output:
* 10..25 --> modified region new region bounduaries are lines from 10 to 25
15..20 --> region _NOT_ modified but new region bounduaries are lines from 15 to 20 (perhaps patch added 5 lines _before_ the region)
10..15 ---> region _NOT_ modified and lines, if any, added/removed _after_ the region
* 10..15 --> modified region with the same boundiaries (as example removing trailing witespaces)
With this new option of git-diff-tree becames very simple to retrieve a file history limited to a region, because the region bounduaries in ouput from one rev are feed as input in parent rev.
Comments?
Marco