views:

411

answers:

1

Our ASP.NET web shop is starting to move from VisualSourceSafe to Subversion (VisualSVN/TortoiseSVN).

Subversion needs to have all files residing in a single directory tree. This is simple when using a Web Application Projects - everything lives in

  • \Visual Studio 2008\Projects\MyProject

With a Web Deployment Project, though, it's a bit of a mess. You have

  • \Visual Studio 2008\Website\MyProject for the website itself
  • \Visual Studio 2008\Projects\MyProject for the solution file
  • \Visual Studio 2008\Projects\MyProject\MyProject_deploy containing a complete "deployment" version of the website

What's the best practice for managing this in SVN? Should I just move the website under \Visual Studio 2008\Projects\MyProject and add the whole thing to the repository, including the deployment version of the site?

+2  A: 

Best practice is to leave your solution file at the root of your project structure, with every project in a sub-folder. That way, each project can be checked out individually without the solution file if people wish to do so.

So in your case, you should have, in your SVN repository, something like:

svn://{repository_root}/MyProject/Website/ {all website files including the .proj file} svn://{repository_root}/MyProject/WebsiteDeployment/ { all deployment files including .proj file} svn://{repository_root}/MyProject/MyProject.sln

So the answer to your question is yes, you should move everything under a folder called "MyProject".

Edit: you should also consider having MyProject/Trunk, MyProject/Tags, and MyProject/Branches, which is considered best practice according to the SVN Manual.

womp
Thanks, that works well.
Herb Caudill