I want to convert a Subversion repository sub-directory (denoted by module
here) into a git repository with full history. There are many svn copy
operations (Subversion people call them branches) in the history of my Subversion repository. The release policy has been that after each release or other branches created, the old URL is left unused and the new URL replaces the old one for containing the work.
Optimally, by my reading, it seems like this should do the trick:
$ git svn clone --username=mysvnusername --authors-file=authors.txt \
--follow-parent \
http://svnserver/svn/src/branches/x/y/apps/module module
(where branches/x/y/
depicts the newest branch). But I got an error, which looks something like this:
W: Ignoring error from SVN, path probably does not exist: (160013): Filesystem has no item: '/svn/src/!svn/bc/100/branches/x/y/apps/module' path not found
W: Do not be alarmed at the above message git-svn is just searching aggressively for old history.
(Update: Adding option --no-minimize-url
to the above does not remove the error message.)
The directory module
get created and populated, but the Subversion history past the newest svn copy
commit is not imported (the git repository created ends up having just two commits when I expected hundreds).
The question is, how to export the full Subversion history in the presence of this situation?
Possible Cause
Searching for the error message, I found this: git-svn anonymous checkout fails with -s which linked to this Subversion issue: http://subversion.tigris.org/issues/show_bug.cgi?id=3242
What I understand by my reading, something in Subversion 1.5 changed about how the client accesses the repository. With newer Subversion, if there is no read access to some super directory of the URL path (true for me,
svn ls http://svnserver/svn
fails with403 Forbidden
), then we fail with some Subversion operations.Jeff Fairley in his answer points out that spaces in the Subversion URL might also cause this error message (confirmed by user Owen). Have a look at his solution to see how he solved the case if your
git svn clone
is failing for the same resson.Dejay Clayton in his answer reveals that if the deepest subdirectory components in branch and tag svn urls are equally named (e.g.
.../tags/release/1.0.0
and.../branches/release-candidates/1.0.0
) then this error could occur.