The single directory layout means there's only one single directory where everything resides. The simplest case is that where all the files and directories reside right in the repository root and there are no branches or tags:
/repository dir1 … dirN file1 … fileN
Correct configuration for this case is the following:
Note, that in such case (repository root is used) it's impossible to add branches or tags later.
Another kind of the single directory layout is an SVN repository hosting more than one project, each project lives in its own directory inside the repository and each projects' files are stored right in the project directory root:
/repository /project_1 dir1 … dirN file1 … fileN /project_2 … /project_N
There are two possible configurations for this case.
In the first, the URL is set leading to the project root and all the mapping options are disabled:
Note that this configuration doesn't allow to add branches and tags later.
Another possible configuration for this case is that the URL leads to the repository and trunk option is set to point to project directory:
In this branches and tags can be added to configuration later just by enabling appropriate line in the configuration.
One more common case is that only one particular branch has to be translated to Git. The repository and project can be arbitrary complex, e.g.:
/svn /repository /project /trunk /branches /branch_1 … /bugs … /features … /tags … /major_releases /minor_releases …
but if only branch_1 needs to be translated - it can be done as simply as
url = http://example.com/svn/repository/project/branches trunk = branch_1:refs/heads/master #branches = branches/*:refs/heads/* #tags = tags/*:refs/tags/* #shelves = shelves/*:refs/shelves/*
that is, we set
svn.url to point to the branches directory inside the project directory and set branch_1 to be
Another way is to set
svn.url to point directly to the branch_1 directory:
url = http://example.com/svn/repository/project/branches/branch_1
and comment (or remove) all the rest options:
#trunk = trunk:refs/heads/master #branches = branches/*:refs/heads/* #tags = tags/*:refs/tags/* #shelves = shelves/*:refs/shelves/*
Both ways are equivalent - the branch_1 will be translated into Git's master branch.