Using Visual SourceSafe - Basic operations
This article is a part of SourceSafe / VSS Tutorial
I only put basic introduction of SourceSafe / VSS version control operations in this post. For detailed information about SourceSafe operations, like Add, Get, Check In and Undo, please refer to the upcoming posts.
Add is the starting point of all VSS file operations. Before you can do Get, Check In, Check Out or other operations, the file needs to be under the control of VSS first.
You can add individual files and folders into VSS database.
Screen shots of Add File:
(Screen shot: Add File in VSS 6)
(Screen shot: Add File in VSS 2005)
When you want to view/get a file or project, but not modify it, you can use the Get or View command. Get copies the file or project from the current project into your working folder.
Get Latest Version, which retrieves the most recent version of a file or a project to your working folder, is the most commonly used command in VSS.
Screen Shot of Get:
(Screen shot: Get Latest)
To make changes to a file you must first check it out of the VSS database. When you Check Out an item, VSS retrieves the latest copy of the file to your working folder and make it writable.
There are exclusive check out and non-exclusive check out. If a file is checked out exclusively, it cannot be checked out by other users.
Please always check out a file first before making any changes for the following reasons:
- If a file is not checked out, it cannot be checked in;
- If a file is not checked out, your local copy may not be the latest copy. Not working on a latest copy may cause extra work, overwriting other’s changes, confusion and many other problems;
- If we change a file without checking it out first, other team members can check out the file and make changes to it, which can cause huge problem if parallel changes to a file is not desired.
This is the classical lock-modify-unlock model of VSS. Other tools like CVS and SubVersion have very different models. The latest VSS 2005 also supports the Copy-Modify-Merge model. We will discuss the details later in the coming articles.
Screen shot of Check Out:
(Screen shot: Check Out)
After you have finished the changes, you need to Check In the updated file back into VSS. When we say VSS keeps all your previous changes, we are not saying that VSS keeps every change you make, we are saying that VSS keeps all the versions you checked in. If you do not check in your file, there is no way that VSS knows that you have changed the file and it should keep it.
Screen shot of Check In:
(Screen shot: Check In)
The SQL Server-based Source Control Software Designed to be a SourceSafe Replacement
The Fastest SourceSafe Remote Access Tool Recommeded by Microsoft