What Files Shoud Go In Source Control

I was searching for some guidance on this and came across a nice paper:

Explained :Structuring Your Solutions And Projects In Source control Using Team Foundation Server

What Files Should Be Source Controlled?

The following list identifies the key file types that you should add to source control. These are the file types that are added when you click Add Solution to Source Control.

Solution files (*.sln). Solution files maintain a list of constituent projects, dependencies information, build configuration details, and source control provider details.

Project files (*.csproj or *.vbproj). Project files include assembly build settings, referenced assemblies (by name and path), and a file inventory.

Visual Studio Source Control Project Metadata (*.vspscc). These files maintain project bindings, exclusion lists, source control provider names and other source control metadata.

Application configuration files (*.config). XML configuration files contain project and application specific details used to control your applications ’s run time behavior.

 

Web applications use files called Web.config. Non-Web applications use files called App.config.

Note: At run time, the Visual Studio build system copies App.config to your project’s Bin folder and renames it as Yourappname.exe.config. For non-Web applications, a configuration file is not automatically added to a new project. If you require one, add it manually. Make sure you call it App.config and locate it within the project folder.

Source files (*.aspx, *.asmx, *.cs, *.vb, …). Source code files, depending on application type and language.

Binary dependencies (*.dll). If your project relies on binary dependencies such as third party DLLs, you should also add these to your project within source control. For more information about managing dependencies, see “Explained: Managing Source Control Dependencies in Visual Studio Team System.”

What Files Should Not Be Source Controlled?

The following files are not added to source control because they are developer specific:

Solution user option files (*.suo). These contain personalized customizations made to the Visual Studio IDE by an individual developer.

Project user option files (*.csproj.user or *.vbproj.user). These files contain developer specific project options and an optional reference path that is used by the Visual Studio to locate referenced assemblies.

WebInfo files (*.csproj.webinfo or *.vbproj.webinfo). This file keeps track of a project’s virtual root location. This is not added to source control to allow individual developers to specify different virtual roots for their own working copy of the project. While this capability exists, you and all team members are recommended to use a consistent (local) virtual root location when you develop Web applications.

Build outputs that include assembly dynamic-link libraries (DLLs), Interop assembly DLLs and executable files (EXEs). Note that you are advised to add assemblies that are not built as part of your system build process (such as third-party controls and libraries) to Source Control within the projects that reference them.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s