Goal: I need a convenient and efficient way to identify the immediate
copy/move source path and revision of a specified path and revision.
Use case: The case I have in mind right now revolves around use of
this copyfrom info in a 'merge' dialog, as part of an algorithm for
suggesting the most likely merge source (e.g. for a feature branch
forked off of trunk).
I believe that we should have a public convenience API for retrieving
this information, rather than requiring library consumers to implement
it using a log receiver (I've already seen this code used in three
a) A stand-alone API which can be called by library consumers. The
svn_clien_copyfrom_info() API, as defined in the attached patch, is an
b) New "retrieve_copyfrom_info" flag for the svn_client_info() API,
and expanded semantics for use of svn_info_t's copyfrom_path and
copyfrom_rev fields. This flag would exist to avoid potentially
expensive processing for callers which don't need coypfrom info, and
maintain backwards compatibility.
Is there a more efficient way to implement this lookup than through a
custom log receiver (as in the attached patch)? Using a log receiver
written directly against libsvn_repos doesn't seem to buy us much in
terms of efficiency -- the copyfrom info lookup remains an O(N)
Received on Sat Mar 31 00:33:01 2007
- application/pgp-signature attachment: stored