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

Re: possible improvement to svn log with "forward" revision range

From: Avalon <third-chance_at_gmx.de>
Date: Mon, 07 Mar 2011 19:21:37 +0100

>> I am explicitly interest in finding a more recent revision than N of a
>> specific resource.
>> svn log -r N:HEAD path-of-resource_at_N
>> It is possible to find older revision (-r N:1 path_at_N) and the resource must
>> not exist in revision one.
> I think you essentially want Subversion to apply some more heuristics to the
> guesswork it already does for forward-directory history searching. Like, if
> PATH_at_HEAD doesn't exist, attempt to determine the last revision in which
> PATH_at_LAST-REV does exist, and then use *that* for the log search. Right?

from the implementation view you might be right.

For the backward search (-r N:1) svn just outputs all relevant revision until the resource has been added initially.
I know that it is more difficult for svn to "go forward" in history.
But it would be great if it could work the same way.

Currently the simple question "show the most recent version of the resource identified by path_at_N?" can not be answered (as long as it is not in head (and with the same path - but that would be even
more difficult)).
Implementing this in userland code requires to basically do a binary search between revision N and HEAD to determine until when the resource exists and then call the appropriate log command with "-r
N:X" whereas X might be anywhere between N and HEAD.

Could this feature (not actually the algorithm) be integrate into SVN so that the user can just call svn log with a forward revision range?

Received on 2011-03-07 19:22:11 CET

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

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.