How to Use Visual Studio. NET to manage source code using CVS

Source: Internet
Author: User

Visual Studio. NET

HowUseCVSManagementSource code

Address: http://blog.csdn.net/mongmong/archive/2004/08/30/88447.aspx
Visual Studio. NETSameMicrosoftOfVisual sourcesafeGood integration, so many people are usingVisual Studio. NETIt is natural to use it during development.Visual sourcesafeAs its source code management tool. But when the project needs to useCVSAs sourceCodeWhen managing tools,Visual Studio. NETWhat should we do? This article will show you how to configureCVSMatchVisual Studio. NETSeamless integration.

 

1Required Software

Cvsnt:Http://www.cvsnt.com
(Select hereCvsnt v2.0.51bServer)

IGLOO:Http://www.jalindi.com/igloo/
Http://www.devhood.com/tools/tool_details.aspx? Tool_id = 491
(Visual Studio. NETPlug-in for accessingCVS),IGLOOAfter the installation is successful,Visual Studio. NETBy defaultSource ControlWill useCVS

 

2, ConfigurationCVSServer

If you use an existingCVSYou can skip this step.

CvsntAfter the installation is successful, a menu item is displayed in the Start Menu."Cvsnt/Service Control Panel"And in the control panel, there will be"Cvs for NT". Click one of them to open the following window:

(Figure 1)

InRepositoriesTo add the specified directory as the code repository. If the specified directory is still notCvsntRecognized repositories,CvsntInitialize the directory. 2:

(Figure 2)

Check if necessaryAdvancedUnder the tagTemporary directoryWhether it is a correct value. If the specified directory does not existVisual Studio. NETDuring the operation, an error is reported, indicating that a Temporary Folder cannot be created. 3:

(Figure 3)

 

3, CreateVisual Studio. NETAdd the projectCVSMedium

 

AndSourcesafeCompared,CVSInRepositoryEquivalentSourcesafeInDatabase,CVSInModuleOne-to-one correspondence with the client directory structure. Therefore,Visual Studio. NETIn directory, the solution is saved inCVSCorrespondingModuleS.

A) Create a newVisual Studio. NETProject (arbitrary ),SolutionThe view is as follows:

(Figure 4)

In this caseVs. netThere isCvssolutionSolution (Solution) AndCvssolutionThere isTestcvsProject (Project).

B) SetCvssolutionJoinCVS

Right-clickSolutionView, select"Add solution to source control ...", The following dialog box is displayed:

(Figure 5)

CVSGenerallyPserverProtocol,CvsrootThe format is as follows:

: Pserver: Username: Pasword@ Hostname: Repository

HereRepositorySelectMyfirstrepository, ClickCheckClick to test the server connection.CVS LoginDialog box, prompting you to enter the password (of course, the password can also be inCvsroot):

(Figure 6)

If the connection is successful, the following dialog box is displayed. Otherwise, an error occurs:

(Figure 7)

There are two items in the module information: the CVS module and the vendor. Generally, the CVS module should have the same name as the object (solution here) added to the CVS. Vendor can be modified according to your preferences.

If the specified module already exists, click Connect. Otherwise, click Create to create a new module. Because we add a new project to CVS, we should create a new module. If the module cvssolution is successfully created, the system will prompt you to add the project testcvs to CVS:

(Figure 8)

Compared with figure 5, the localpath becomes the directory where the testcvs project is located, and the CVS module defaults to cvssolution./TestcvsIndicates that the path of this module is under the module of cvssolution. Click Create to create the corresponding module in the directory where testcvs is located. Cvssolution/TestcvsAfter creation, the files in solution will be checked in to CVS.

So far, Visual Studio. NetThe project and CVs are officially linked. You can perform check in and check out operations on the project files to test whether CVS works normally.

You can refer to the above method to add a newly added project to solution to CVS.

 

4. Conclusion

In Visual Studio. NetThe process of using CVS in is similar to that of sourcesafe, but it is slightly different from that of sourcesafe in configuration and user interface, for example, during file comparison and other operations, iGLOO displays the output of CVS in the output window.

This document is only used as Visual Studio. NetAndCVSIn combination with the introduction, more skills need to be explored by the user.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.