I often read some programs. Some solutions have multiple projects. Because there are many codes and many developers, many projects under vs.net use source safe for version control. Source safe requires LAN path sharing for version control. Therefore, many projects may encounter some problems when switching to another machine. For example, "The solution seems to be managed by source code, but cannot find its binding information ......" And so on. Sometimes the modified Code cannot be saved, so I want to remove it. Below are some comparisons before and after project management.
1. Project comparison
Compared with projects that are not managed by Source Safe code:
1. The. scc,. vssscc, And. vspscc files are added;
2. C # add several lines of labels to the project file (. csproj:
SccProjectName = "SAK"
SccLocalPath = "SAK"
SccAuxPath = "SAK"
SccProvider = "SAK"
3. In the solution file (. sln), add the following node elements:
GlobalSection (SourceCodeControl) = preSolution
SccNumberOfProjects = 4
SccLocalPath0 =.
......
SccLocalPath3 = SUBSCRIBE_TOOLS
CanCheckoutShared = false
EndGlobalSection
Ii. Compile the implemented classes
Since the number of files has increased and some files have been modified, I want to change them back to their original state through programming. This may remove the prompt information, so I wrote the following code.
File: //************************************** *
// Procedure: Zheng ZuoZhzuocn@163.com2004/06/10
// Function: Remove Source safe management from the original code of C #. net
File: //************************************** *
Using System;
Using System. IO;
Using System. Text;
Using System. Threading;
Namespace ZZ
{
/// <Summary>
/// Operation information event proxy
/// </Summary>
Public delegate void OperateNotifyHandler (object sender, VssEventArgs e );
/// <Summary>
/// VssConverter processes the SourceSafe Association of the solution or project.
/// </Summary>
Public class VssConverter
{
File: // operationRoot directory
Private string operatePath;
/// <Summary>
/// Operation information event
/// </Summary>
Public event OperateNotifyHandler OperateNotify;
/// <Summary>
/// Thread end notification event
/// </Summary>
Public event EventHandler ThreadCompleted;