Content by Category
.NET 1.x
.NET 2.0
.NET 3.0
.NET 3.5
.NET 4.0
.NET Assemblies
.NET Framework
.NET Getting Started
Accessibility
ADO.NET
Advertorials
Agile Development
AJAX
Architecture
ASP.NET
ASP.NET MVC
ASP.NET WebForms
Azure
B2B (Business Integration)
Bing
BizTalk
Book Excerpts
Build and Deploy
C#
C++
ClickOnce
Cloud Computing
Code Contracts
CODE on the Road!
COM+
Community
Conferences
Continuous Integration
Crystal Reports
CSLA.NET
CSS
Data
Design Patterns
Development Process
Display Technologies
Distributed Computing
DotNetNuke
DSL
Dynamic Programming
Editorials
Enterprise Services ("COM+")
Entity Framework
Events
Expression Blend
F#
Fox to Fox
Frameworks
Functional Programming
Git
Graphics
Internet Explorer 8.0
Interviews
iPhone
Iron Ruby
Java
Java Script
jQuery
LINQ
Linux
Mac OS X
MDX
Microsoft Application Blocks
Microsoft Business Rules Framework
Microsoft Dynamics
Microsoft Expression
Microsoft Office
Mobile Development
Mobile PC
Mono
MsBuild
Network
NHibernate
Object Oriented Development
Odata
Open Source
Opinion
Opinions
Oracle
ORM
Other Languages
Parallel Programming
Patterns
Podcasts
Post Mortem
PowerPoint
Print/Output
Prism
Product News
Product Reviews
Project Management
Python
Q&A
Rails
Rake
Reporting Services
REST
RIA Services
Ruby
Ruby on Rails
Search
Security
Services
SharePoint
Silverlight
SOA
Social Networks
Software & Law
Software Business
Source Control
Speech-Enabled Applications
SQL Server
SQL Server 2000
SQL Server 2005
SQL Server 2008
SQL Server CE/AnyWhere/Mobile/Compact
SSIS
Subversion
Sync Framework
Tablet PC
TDD
Team System
Techniques
Testing and Quality Control
Tips
UI Design
UML
User Groups
VB Script
VB.NET
Version Control
VFP and .NET
VFP and SQL Server
Virtual Earth
Vista
Visual Basic
Visual Basic 6 (and older)
Visual FoxPro
Visual Studio .NET
Visual Studio 2005
Visual Studio 2008
Visual Studio 2010
Visual Studio Tools for Office
VSX
WCF
Web Development (general)
Web Services
WF
Whitepapers
Windows 7
Windows Azure
Windows Live
Windows Server
Windows Vista
WinForms
Workflow
WPF
XAML
XML
XNA
XSLT



Free Webinar


 


Devscovery

Reader rating:
Click here to read 12 comments about this article.
Article source: CoDe (2008 Jul/Aug)


Article Pages:  1  2 3 4 - Next >


Setting Up and Running Subversion and Tortoise SVN with Visual Studio and .NET

Source control is an important aspect in software development even if you are not doing team development. It can help you manage your application more efficiently and make sure that your project is backed up and can be rolled back to any revision on the file or project level. I recently got acquainted with the open source Subversion and Tortoise SVN tools and, for the first time, feel that this is source control that I can live with comfortably. This article describes all you need to know to get started with Subversion and Tortoise SVN for Visual Studio projects.

This article describes the steps to install and configure the Subversion source control tool and walks you through the basic steps required to set up local Visual Studio projects using Tortoise SVN.

"
Subversion typically runs as a Service either using TCP/IP or HTTP, the latter of which requires Apache.
"

This article isn’t meant to be a comprehensive tutorial on Subversion, but rather a quick, what-you-need-to-know, step-by-step guide to the essential tools to install and configure to get up and running.

What Is Subversion?

Subversion is an open source control repository tool. It is widely used by many open source projects and increasingly by many large development teams in general. It’s fast and efficient, small and easy to install and because it’s open source-it’s also free. Subversion is file based and keeps its repository in a simple directory structure that you can copy and back up easily.

You can graphically access Subversion via Tortoise SVN, which is an Explorer Shell Extension that provides access to most of Subversion’s command-line interface through Explorer Context menus and overlay icons for files under source control. This actually is very powerful as it lets you use a familiar Explorer interface as your source code browser and, more importantly, because it very easily lets you see source control files in relation to the actual directory structure and what is and isn’t under source control.

Subversion subscribes to the Copy-Modify-Merge philosophy of source control, which means that files are never locked and nobody ever “owns” a file. Rather Subversion manages changes by merging source files with any changes made and only notifies you of conflicts if there are changes that cannot be merged (i.e., changes to the same line of code typically).

Coming from a background of using integrated security in Visual Studio, I at first had my doubts about the merge approach. However, I’m finding that it allows considerably smoother development as you don’t have to worry about constant check-out/check-in scenarios and locking files for other users. Instead you simply work on your code and when you’re done you can check in all changes using Tortoise SVN. Not having source control inside of Visual Studio may sound like blasphemy if you’ve used Visual SourceSafe, Vault, or another source code control provider before. I was skeptical about lacking Visual Studio integration when I started out, but I find I really don’t miss the integration with Visual Studio. More importantly, I don’t miss the problems that go with integrated source control in Visual Studio with the provider manager often getting confused, especially in complex Visual Studio Solutions and shared project scenarios. Subversion has actually made many scenarios that used to royally suck and required constant fiddling with Visual Studio and the source providers much easier.

Subversion is based on a file system tracking mechanism, so it is essentially tool agnostic. In fact, I use Subversion now with my .NET projects as well as with my old FoxPro projects-the process is no different, which is great for consistency and allows storage of all sorts of files from documentation to support files that otherwise wouldn’t be part of a Visual Studio project.

Installation

To start, download Subversion and Tortoise SVN and install both.

You can download Subversion from here: http://subversion.tigris.org/

You can download Tortoise SVN from here: http://tortoisesvn.tigris.org/

If you want Visual Studio integration, check out VisualSVN ($49) or the free Ankh tool:

http://www.VisualSvn.com/

http://ankhsvn.tigris.org/

Start by installing Subversion, and then install Tortoise SVN. Tortoise works as a front-end UI to Subversion. Both need to be compatible, so you should always install the latest version of each.

I’ll walk you through the process of creating a new repository and adding a Visual Studio Solution with a couple of projects to it.

If you are not setting up a new repository and just need to create a local copy from Subversion repository, just skip ahead to the Creating a Local Copy section.

Configuration for Tortoise SVN

Before doing anything else, I suggest you make one small configuration change in Tortoise SVN-change the name of the local svn repositories from .svn to _svn.

Make sure you’ve installed Tortoise SVN. Go into Explorer and right-click anywhere on a file or folder. On the shortcut menu, choose TortoiseSVN and choose Settings and check the “Use ‘_svn’ instead of ‘.svn’” check box on the General tab as shown in Figure 1.

Click for a larger version of this image.

Figure 1: It’s a good idea to set up Tortoise SVN to use _svn instead of .svn, since Visual Studio has issues with directories that start with a period.

Visual Studio has issues with folders that start with a period so it’s best to use the _svn prefix, especially if you decide later on to use a tool that integrates with Visual Studio.

&

By: Rick Strahl

Rick Strahl is president of West Wind Technologies in Maui, Hawaii. The company specializes in Web and distributed application development and tools, with focus on Windows Server Products, .NET, Visual Studio, and Visual FoxPro. Rick is the author of West Wind Web Connection, West Wind Web Store, and West Wind HTML Help Builder. He’s also a C# MVP, a frequent contributor to magazines and books, a frequent speaker at international developer conferences, and the co-publisher of CoDe Magazine. For more information please visit his Web site at www.west-wind.com or contact Rick at rstrahl@west-wind.com.

rstrahl@west-wind.com

Fast Facts

Find out how to set up and configure the free, open source Subversion source control system quickly and easily.



Article Pages:  1  2 3 4 - Next Page: 'Create a New Repository with Tortoise SVN' >>

Page 1: Setting Up and Running Subversion and Tortoise SVN with Visual Studio and .NET
Page 2: Create a New Repository with Tortoise SVN
Page 3: Creating a New Top-level Folder
Page 4: Creating a Local Copy from the Repository

How would you rate the quality of this article?
1 2 3 4 5
Poor      Outstanding

Tell us why you rated the content this way. (optional)

Average rating:
4.5 out of 5

24 people have rated this article.

      Free Webinar

 

INSTANTLY dtSearch® TERABYTES OF TEXT