On Mon, 2004-05-31 at 18:34, Julian Foad wrote:
> I have as yet failed to get the hardest part working, which is sorting
> the combination of local and repository information for "svn diff
> -rX[:Y]" and "svn status --show-updates". The crux of this seems to
> be sorting the various add/change/delete operations within
> subversion/libsvn_repos/reporter.c (delta_dirs), but when I try to do
> that various things fail. It may be theoretically impossible but I do
> not yet see any reason why. I may try that again and/or request help
> on it later, but, even without it, having local operations sorted
> seems very nice to me.
Well, it's possible, but it's not easy, so I'm not sure if it's worth
it. There are two big cans of worms:
#1: Instead of traversing the report information followed by the
target information followed by the source information, we have to
traverse the (sorted) source and target information at the same time as
the report (asking, at each step, which comes next lexically: a source
item, a target item, or a report item). And we have to behave correctly
if the client's report isn't sorted (because the report could have come
from a 1.0 client). (By "correctly" I mean we have to display all the
right output, but not necessarily in alphabetical order.)
#2: Frequently, on the libsvn_wc side of things, the editor's
close_directory() handler will process everything the server didn't
mention. For instance, "svn st -u" will (I presume) report on status
actions received from the server and then, when the directory is closed,
report on locally modified or added files not mentioned by the server
(and also recurse into subdirectories not mentioned by the server). All
these editors would have to be changed to, each time the server mentions
something, iterate over all the local items which alphabetically preceed
it. Again, we have to behave correctly if the server's output isn't
sorted, since it might be a 1.0 server.
Given how hard it is to get it right, I'm not sure if we want to do it
half-assed. It seems like it could lead to questions, or in the extreme
case, incorrect scripts, when people become used to seeing alphabetical
behavior in most-but-not-all cases.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Tue Jun 1 04:51:46 2004