« Microsoft Makes Vista Prices Official | ^ Main | Flex Goodness: enterDebugger() »


Subversion Trials on Windows (without Apache)

Ok…it is easy but it isn’t. There isn’t 1 central location for Subversion (SVN) help on Windows. Well, let me rephrase that. There isn’t 1 central location for SVN help on Windows. :-) After thinking about it, that statement is accurate. lol.

Fine, fine, fine, fine! Comment with all of your links, etc but Google doesn’t seem to find that 1 location with all of the help I need. I was able to piece together different information about the setup, etc and get it going and, come to find out, it is quite easy. So, I figured I would post what I did and hopefully help someone else out in the process. I’m not going to get into using SVN or which database type you should use. That’s up to you. We’re dealing with connection only here.

  1. Download SVN here and install it on your server. Just use the default install location, etc.
  2. Download SrvAny here and install. More info on how to use it can be found here.
  3. (flexible step) Test your needs for SVN connections through the command prompt. What I mean is, there are multiple ways to connect to SVN and here is where you need to figure out what your biz/organization needs. Here are some samples (Just keep in mind you are in control here. It is what you need):
    1. svnserve -r c:\myfolder\myrepos\ —listen-host svn.myserver.com -d
    2. svnserve -r c:\blah\repos\ —listen-port 80 —listen-host 55.55.55.55 -i
  4. Start->Run->(type) CMD and press Enter
  5. Go to the location of your SrvAny and InstSrv files using normal dos commands (cd, etc)
  6. Type: Instsrv “Subversion Server” c:\{location of srvany}\srvany.exe (Subversion Server can be whatever you want it to be) and hit Enter. This creates a service called “Subversion Server” which can be turned on/off as needed. If you need to provide a username/password for the service you can use -a and -p. Type Instsrv in the command prompt and you’ll get the help info.
  7. Now we have a service created. All we need to do is tell SrvAny what to run and how. So, you still have the command prompt open, right? Type: regedit.
  8. In the Registry Editor go to: HKEY_LOCAL_MACHINE/SYSTEM/CurrentControlSet/Services/Subversion Server.
    1. Add a new Key called Parameters. Select the key.
    2. Add a new String value called Application and another called AppParameters.
      1. Application is the location of svnserve.exe. If you used the default install it will be here: c:\Program Files\Subversion\bin\svnserve.exe.
      2. AppParameters is what you found to be the connection you needed in step 6 above.
  9. Open the Services panel (Administrative Tools->Services) and find the service you created in step 6. Make sure it is started and set to automatic.
  10. svn://{your connection here} will connect you. You are good to go now.

These instructions are HIGHLY general because there isn’t 1 way that everyone connects to svn. There are tons of other ways and some people may want to go the Apache route but getting Apache and IIS to run side-by-side isn’t an easy task unless you slide Apache & IIS some digital money under the table. :-) (and I don’t mean the companies behind them)

For those of you looking for a great article on how to use SVN in a software dev environment, check out this article by Scott Hanselman - Example: How to contribute a patch to an Open Source Project like DasBlog. It is super thorough on how to apply a patch, etc.

I hope this helps save someone a few strands of hair. Look for more posts soon regarding hooks, usage, etc.

Posted by John C. Bland II on September 9, 2006 10:23 AM |

TrackBack

TrackBack URL for this entry:
http://mt.katapultmedia.com/mt-tb.cgi/211

Post a comment