20

如何使用 svn 命令行或 svnadmin 来创建推荐的目录结构主干等。我做了 mkdir 但什么也没显示?如何创建这些目录?

无法使用工具连接,所以只想先创建这些基本目录。

所以让我知道如何使用命令行或帮助:SVNAdmin Create Repository URL not working

4

1 回答 1

30

Did you read the Subversion manual? This is one of the best open source instruction manuals in the world. Go through the first few chapters and try the examples. Heck, they show you exactly how to do what you want.

You are talking about two separate structures: The repository directory that may be on a completely different machine, and the working directory where you've checked out your work.

You need to create a repository. Once you do that, you can use the svn mkdir command to either make your directory structure without a working directory:

$ svn mkdir --parents -m" Creating basic directory structure" \
    svn://my_repo/trunk svn://my_repo/branches svn://my_repo/tags

Or, you can checkout a copy of the repository in into a working directory and do everything from there:

C> svn co svn://my_repo workingdir
C> cd workingdir
C> svn mkdir trunk tags branches
C> svn commit -m"Creating basic directory structure"

Notice that you will not see the directories directly inside your repository. However, you can use the svn ls command to see the structure:

C> svn ls -R svn://my_repo
于 2012-11-16T02:27:38.940 回答