Source Control and Visual InterDev

 

Microsoft Corporation

July 1998

Your Web pages can easily grow into a large set of files. To keep your Web pages fresh and current, you may need a team of people to create and maintain those files. Whether you are working on a team or by yourself, you can track and save your changes to files easily using Microsoft® Visual SourceSafe® in unison with Microsoft Visual InterDev®.

Visual SourceSafe saves past versions of the files in a database, tracks the date and time of changes, and provides an option to keep a comment log. The most commonly used Visual SourceSafe commands are available directly from within Visual InterDev.

To take full advantage of source control from within Visual InterDev, you need to understand the following concepts:

  • the components for source control
  • your interaction with Visual SourceSafe
  • the interaction between Visual InterDev and Visual SourceSafe

The Components for Source Control

To use source control with your Web files, you need the following items.

  • Visual SourceSafe server installed on your Web server with the integration option selected. You can install Visual SourceSafe Server on a separate machine but it is not recommended.

    Note   Installing the Visual SourceSafe client on your developer workstation is optional. The client is not necessary for checking your Web files in and out as long as Visual SourceSafe is installed on the Web server.

  • FrontPage® Extensions installed on the Web server. Visual InterDev uses the FrontPage Extensions to send commands to Visual SourceSafe.

  • Visual InterDev installed on your developer workstation.

  • Source control enabled on the Web project and set to use Visual SourceSafe on the Web server.

Note   For best results with source control, use Visual SourceSafe on a server running Windows NT® with an NTFS file system.

Your Interaction with Visual SourceSafe

You can interact with Visual SourceSafe on several levels depending on the task you want to complete. Some tasks need to be performed only once, while others may take place on a regular basis.

After you have Visual SourceSafe installed and enabled for your Web pages, you can typically work directly in Visual InterDev. Visual SourceSafe and Visual InterDev work together seamlessly to track your file changes as you add, save, and remove files in your Web project. Any changes you make to your Web files are propagated to the Visual SourceSafe project without requiring you to open Visual SourceSafe.

When you check out a file in your Web project, you get a write-enabled copy of the file. When you check the file in, the new version is copied to the server and is sent to the Visual SourceSafe repository.

The following table shows a list of typical tasks you might perform, how often you may need to perform the tasks, and the interface you use to complete the task. For more information about each task, see the Visual InterDev documentation.

Table 1. Visual SourceSafe tasks

Task Frequency Software used
Installing and setting up Visual SourceSafe Once for each Web server Windows® and Visual SourceSafe Setup
Setting options for multiuser checkout Occasionally as needed Visual SourceSafe Administrator
Adding source control to Web pages Once for each Web page Visual InterDev
Checking files in and out Often as needed Visual InterDev
Setting checkout code options Occasionally as needed Visual InterDev
Reviewing file history Occasionally as needed Visual SourceSafe Explorer*
Restoring past versions Occasionally as needed Visual SourceSafe Explorer*

* If you're using a proxy server for remote access, you won't be able to use the Visual SourceSafe Explorer to view your Visual SourceSafe database because the Explorer requires a LAN connection.

The Interaction between Visual InterDev and Visual SourceSafe

Visual InterDev and Visual SourceSafe interact through the FrontPage server extensions. Typically the Visual SourceSafe and the FrontPage extensions reside on the same machine working against the same Web server. You can install Visual SourceSafe Server on a separate machine but it is not recommended. If you have Microsoft Internet Information Server 4.0, you can have multiple virtual Web servers, but a single Visual SourceSafe project can reference only one.

The FrontPage server extensions provide HTTP connection services between Visual InterDev and other services on the Web server. When you check in a file, the file moves from Visual InterDev on your developer workstation to the FrontPage extensions, which updates the Visual SourceSafe database. Visual SourceSafe adds the copy to its repository along with a record of the date, time, and user who checked the file in. If you choose to add comments, this text is included as well.

This table shows what happens when you perform common file commands.

Table 2. Common file commands

Task Action
Check out and open a file Checks if the file is already checked out exclusively. If not, checks out the file and places a write-enabled copy on your workstation.
Save a file Updates the file on the Web server but the file is not checked in to Visual SourceSafe.
Check in a file Checks in the file and updates the copy in Visual SourceSafe. Depending on your check-in options, it may also remove the write-enabled copy from the local Web pages.