http://www.jetbrains.com/teamcity/documentation/index.html
Read "in short" below for my steps
Setting up Subversion on Windows
When it comes to readily available, free source control, I don't think you can do better than Subversion at the moment. I'm not necessarily advocating Subversion; there are plenty of other great source control systems out there — but few can match the ubiquity and relative simplicity of Subversion. Beyond that, source control is source control, as long as you're not using Visual SourceSafe. And did I mention that Subversion is … free?
Allow me to illustrate how straightforward it is to get a small Subversion server and client going on Windows. It'll take all of 30 minutes, tops, I promise. And that's assuming you read slowly.
The first thing we'll do is download the latest Subversion Windows binary installer. At the time of writing, that's 1.46. I recommend overriding the default install path and going with something shorter:
C:\PROGRA~1\Subversion\
Note that the installer adds C:\PROGRA~1\Subversion\bin
to your path, so you can launch a command prompt and start working with it immediately. Let's create our first source repository, which is effectively a system path.
svnadmin create "D:\QBW_Subversion\repository"
Within that newly created folder, uncomment the following lines in the conf/svnserve.conf file by removing the pound character from the start of each line:
anon-access = noneauth-access = writepassword-db = passwd
Next, add some users to the conf/passwd file. You can uncomment the default harry and sally users to play with, or add your own:
harry = harryssecretsally = sallyssecret
As of Subversion 1.4, you can easily install Subversion as a Windows service, so it's always available. Just issue the following command:
sc create svnserver binpath= "C:\PROGRA~1\Subversion\bin\svnserve.exe --service -r D:\QBW_Subversion\repository" displayname= "Subversion" depend= Tcpip start= auto
It's set to auto-start so it will start up automatically when the server is rebooted, but it's not running yet. Let's fix that:
net start svnserver
Note that the service is running under the Local System account. Normally, this is OK, but if you plan to implement any Subversion hook scripts later, you may want to switch the service identity to an Administrator account with more permissions. This is easy enough to do through the traditional Windows services GUI.
Now let's verify that things are working locally by adding a root-level folder in source control for our new project, aptly named myproject.
set SVN_EDITOR=c:\windows\system32\notepad.exesvn mkdir svn://localhost/myproject
It's a little weird when running locally on the server, as Subversion will pop up a copy of Notepad with a place for us to enter commit comments. Every good programmer always comments their source control actions, right?
Enter whatever comment you like, then save and close Notepad. You'll be prompted for credentials at this point; ignore the prompt for Administrator credentials and press enter. Use the credentials you set up earlier in the conf/passwd
file. If everything goes to plan, you should be rewarded with a "committed revision 1" message.
svn mkdir svn://localhost/myprojectAuthentication realm: <svn://localhost:3690>Password for 'Administrator': [enter]Authentication realm: <svn://localhost:3690>Username: sallyPassword for 'sally': ************Committed revision 1.
Congratulations! You just checked your first change into source control!
Eclipse connection:
use: svn://q-berry-whs
In short:
svnadmin create "D:\QBW_Subversion\repository"
sc create svnserver binpath= "C:\PROGRA~1\Subversion\bin\svnserve.exe –service -r D:\QBW_Subversion\repository" displayname= "Subversion" depend= Tcpip start= auto
Set the user on the service.
net start svnserver
set SVN_EDITOR=c:\windows\system32\notepad.exe
svn mkdir svn://localhost/myproject