一、下载安装
http://subversion.tigris.org/servlets/ProjectDocumentList?folderID=91
默认安装即可。
二、建立Repository
1. 创建目录,例如:c:\svnsrc\csharp
2. 打开命令窗口, 键入 :svnadmin create --fs-type fsfs c:\svnsrc\csharp
三、配置Repository
进入Repository目录,在本文中是 c:\svnsrc\csharp ,你会看到conf目录,进入该目录,你会看到svnserve.conf和passwd两个文件
对两个文件作如下修改
svnserve.conf
### This file controls the configuration of the svnserve daemon, if you
### use it to allow access to this repository. (If you only allow
### access through http: and/or file: URLs, then this file is
### irrelevant.)
### Visit http://subversion.tigris.org/ for more information.
[general]
### These options control access to the repository for unauthenticated
### and authenticated users. Valid values are "write", "read",
### and "none". The sample settings below are the defaults.
anon-access = read
auth-access = write
### The password-db option controls the location of the password-db = passwd
### database file. Unless you specify a path starting with a /,
### the file's location is relative to the conf directory.
### Uncomment the line below to use the default password file.
password-db = passwd
### The authz-db option controls the location of the authorization
### rules for path-based access control. Unless you specify a path
### starting with a /, the file's location is relative to the conf
### directory. If you don't specify an authz-db, no path-based access
### control is done.
### Uncomment the line below to use the default authorization file.
# authz-db = authz
### This option specifies the authentication realm of the repository.
### If two repositories have the same authentication realm, they should
### have the same password database, and vice versa. The default realm
### is repository's uuid.
# realm = My First Repository
passwd
### This file is an example password file for svnserve.
### Its format is similar to that of svnserve.conf. As shown in the
### example below it contains one section labelled [users].
### The name and password for each user follow, one account per line.
[users]
# harry = harryssecret
# sally = sallyssecret
user = password
四、启动subversion
打开命令窗口键入:svnserve -d -r c:\svnsrc
默认端口是3690,如果不幸这个端口被别的程序暂用,可以通过选项 svnserve -d --listen-port 端口号
url格式为:svn://ip地址//Repository名,在本文中是svn://127.0.0.1/csharp
五、将Subversion安装成windows service
sc create svnservice binpath= "\"C:\Program Files\Subversion\bin\svnserve.exe\" --service -r c:\svnsrc" displayname= SVNService depend= Tcpip start= auto
总结:这样,完成了在windows下架设subversion服务