Speedup common paths in svnmerge.py using the Repository Root information returned by "svn info" even on local paths since SVN 1.3.
Speedup common paths in svnmerge.py using the Repository Root information
returned by "svn info" even on local paths since SVN 1.3.

svnmerge.py needs to compute the repository root several times. Right now
the flow of code is very contorted, and I plan to clean it up so that it
computes it once and reuse it everywhere (instead of relying on memoization).
Anyway, this path cleans up many paths of code so to request the repository
root through a local path when possible, so that it can be computed without
remote access.

 * contrib/client-side/svnmerge.py:
   (get_repo_root): Instead of converting immediately to URL, try running
   "svn info" on a local directory before, since it is faster.
   (url_to_rlpath): Rename to...
   (target_to_rlpath): New function. Accepts both an URL and a local directory,
   and convert it to repository-relative path. If a local directory is
   provided (and the client is at least 1.3), this can be done without any
   remote access.
   (RevisionLog.__init__, get_copyfrom, get_default_head, analyze_head_revs,
   main): Use target_to_rlpath, and provide a local directory instead of
   an URL when available.


git-svn-id: f8a4e5e023278da1e04e203c7fe051e3c4285d88@859699 13f79535-47bb-0310-9956-ffa450edef68

wbond/subversion,wbond/subversion,YueLinHo/Subversion,YueLinHo/Subversion,YueLinHo/Subversion,wbond/subversion,YueLinHo/Subversion,wbond/subversion,YueLinHo/Subversion,wbond/subversion,wbond/subversion,YueLinHo/Subversion,YueLinHo/Subversion,YueLinHo/Subversion,wbond/subversion